Skip to content

Commit 89e4fe0

Browse files
authored
Update mixin-filtering.js
1 parent 55b8ad5 commit 89e4fe0

File tree

1 file changed

+10
-12
lines changed

1 file changed

+10
-12
lines changed

src/components/table/helpers/mixin-filtering.js

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -123,19 +123,17 @@ export default {
123123
handler(newCriteria, oldCriteria) {
124124
newCriteria = this.filterSanitize(newCriteria)
125125
oldCriteria = this.filterSanitize(oldCriteria)
126-
if (!looseEqual(newCriteria, oldCriteria)) {
127-
const timeout = this.computedFilterDebounce
128-
clearTimeout(this.$_filterTimer)
129-
this.$_filterTimer = null
130-
if (timeout && timeout > 0) {
131-
// If we have a debounce time, delay the update of `localFilter`
132-
this.$_filterTimer = setTimeout(() => {
133-
this.localFilter = newCriteria
134-
}, timeout)
135-
} else {
136-
// Otherwise, immediately update `localFilter` with `newFilter` value
126+
const timeout = this.computedFilterDebounce
127+
clearTimeout(this.$_filterTimer)
128+
this.$_filterTimer = null
129+
if (timeout && timeout > 0) {
130+
// If we have a debounce time, delay the update of `localFilter`
131+
this.$_filterTimer = setTimeout(() => {
137132
this.localFilter = newCriteria
138-
}
133+
}, timeout)
134+
} else {
135+
// Otherwise, immediately update `localFilter` with `newFilter` value
136+
this.localFilter = newCriteria
139137
}
140138
}
141139
},

0 commit comments

Comments
 (0)