Skip to content

Commit

Permalink
fix(sdk-ui-filters): undefined workingFilter prop
Browse files Browse the repository at this point in the history
- not sure why TypeScript check is not catching this

JIRA: GDP-2938
risk: low
  • Loading branch information
ondrejvelisek committed Mar 11, 2025
1 parent 87a3d19 commit f53489b
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -364,9 +364,12 @@ function useInitOrReload(
const filterChanged = getFilterChanged(filter, handler, enableDuplicatedLabelValuesInAttributeFilter);

const getWorkingFilterChanged = (
workingFilter: IAttributeFilter,
handler: IMultiSelectAttributeFilterHandler,
workingFilter?: IAttributeFilter,
) => {
if (!workingFilter) {
return false;
}
const { isInverted, keys } = handler.getWorkingSelection();
if (isPositiveAttributeFilter(workingFilter)) {
if (isInverted) {
Expand All @@ -387,7 +390,7 @@ function useInitOrReload(
}
};

const workingFilterChanged = getWorkingFilterChanged(workingFilter, handler);
const workingFilterChanged = getWorkingFilterChanged(handler, workingFilter);

const limitingValidationItemsChanged = !isEqual(
limitingValidationItems,
Expand Down

0 comments on commit f53489b

Please sign in to comment.