diff --git a/ui/src/Components/SilenceModal/Browser/index.js b/ui/src/Components/SilenceModal/Browser/index.js index c5e20aa96..ccc5604e4 100644 --- a/ui/src/Components/SilenceModal/Browser/index.js +++ b/ui/src/Components/SilenceModal/Browser/index.js @@ -93,7 +93,7 @@ const Browser = observer( } ); - onFetch = debounce(() => { + onFetch = () => { const uri = FormatBackendURI( `silences.json?sortReverse=${ this.dataSource.sortReverse ? "1" : "0" @@ -118,7 +118,9 @@ const Browser = observer( `Request failed with: ${err.message}` ); }); - }, 500); + }; + + onDebouncedFetch = debounce(this.onFetch, 500); maxPerPage = 5; @@ -172,7 +174,7 @@ const Browser = observer( checked={this.dataSource.showExpired} onChange={() => { this.dataSource.toggleShowExpired(); - this.onFetch(); + this.onDebouncedFetch(); }} />