Skip to content

Commit

Permalink
Fix opening a filter modal (#4123)
Browse files Browse the repository at this point in the history
Follow-up to #4117

Opening a utm modal crashed if there was an existing page filter. Bug
struck in during a refactoring.
  • Loading branch information
macobo authored May 23, 2024
1 parent ab1416b commit 850cc30
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion assets/js/dashboard/stats/modals/filter-modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ function partitionFilters(modalType, filters) {

filters.forEach((filter, index) => {
const filterGroup = getFilterGroup(filter)
if (FILTER_GROUP_TO_MODAL_TYPE[modalType].includes(filterGroup)) {
if (FILTER_GROUP_TO_MODAL_TYPE[filterGroup] === modalType) {
const key = filterState[filterGroup] ? `${filterGroup}:${index}` : filterGroup
filterState[key] = filter
hasRelevantFilters = true
Expand Down

0 comments on commit 850cc30

Please sign in to comment.