Skip to content

Commit

Permalink
CORE-1999: fix the matching file count when no matching files are found
Browse files Browse the repository at this point in the history
  • Loading branch information
slr71 committed Jun 5, 2024
1 parent 5e448b8 commit dd3d28c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/components/search/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,7 @@ export const getSearchLink = ({ searchTerm = "", advancedDataQuery = "" }) => {
};

export const extractTotal = (result) => {
return result?.total?.value || result?.total;
return typeof result?.total === "object"
? result?.total?.value
: result?.total;
};

0 comments on commit dd3d28c

Please sign in to comment.