Skip to content

Commit

Permalink
clean sort function
Browse files Browse the repository at this point in the history
  • Loading branch information
cretadn22 committed Aug 6, 2024
1 parent bcbbb53 commit 634fe3d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pages/EditReportFieldDropdown.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ function EditReportFieldDropdownPage({onSubmit, fieldKey, fieldValue, fieldOptio
);

const [sections, headerMessage] = useMemo(() => {
const validFieldOptions = fieldOptions?.filter((option) => !!option).sort(localeCompare);
const validFieldOptions = fieldOptions?.filter((option) => !!option)?.sort(localeCompare);

const {policyReportFieldOptions} = OptionsListUtils.getFilteredOptions(
[],
Expand Down

0 comments on commit 634fe3d

Please sign in to comment.