Commit 084d4a57 authored by Kushal Pandya's avatar Kushal Pandya

Merge branch 'ph/6488/approversSelectDebounce' into 'master'

Fix approver select debounce

See merge request gitlab-org/gitlab!84264
parents e22e94ce 71358ace
......@@ -104,6 +104,11 @@ export default {
},
},
mounted() {
const query = debounce(
({ term, callback }) => this.fetchGroupsAndUsers(term).then(callback),
500,
);
import(/* webpackChunkName: 'select2' */ 'select2/select2')
.then(() => {
// eslint-disable-next-line promise/no-nesting
......@@ -117,10 +122,7 @@ export default {
closeOnSelect: false,
formatResult,
formatSelection,
query: debounce(({ term, callback }) => {
// eslint-disable-next-line promise/no-nesting
return this.fetchGroupsAndUsers(term).then(callback);
}, 250),
query,
id: ({ type, id }) => `${type}${id}`,
})
.on('change', (e) => this.onChange(e));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment