Skip to content

Commit

Permalink
suggestions from code reviews
Browse files Browse the repository at this point in the history
  • Loading branch information
sainak committed Nov 11, 2024
1 parent da4cf47 commit ebb9ab9
Showing 1 changed file with 2 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -148,13 +148,8 @@ const NursingPlot = ({ consultationId }: ConsultationTabProps) => {
return filtered.length > 0;
};

const areFieldsEmpty = () => {
let emptyFieldCount = 0;
for (const field of NURSING_CARE_PROCEDURES) {
if (!filterEmpty(field)) emptyFieldCount++;
}
return emptyFieldCount === NURSING_CARE_PROCEDURES.length;
};
const areFieldsEmpty = () =>
NURSING_CARE_PROCEDURES.every((field) => !filterEmpty(field));

const rows = NURSING_CARE_PROCEDURES.filter((f) => filterEmpty(f)).map(
(procedure) => ({
Expand Down

0 comments on commit ebb9ab9

Please sign in to comment.