Skip to content

Commit 3dbbb73

Browse files
committed
edge case when preselected item is not found
Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
1 parent 4a18178 commit 3dbbb73

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

ui/src/components/widgets/InfiniteScrollSelect.vue

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,11 @@ export default {
221221
const match = this.options.find(entry => entry[this.optionValueKey] === matchValue)
222222
if (!match) {
223223
this.successiveFetches++
224-
this.fetchItems()
224+
if (this.options.length < this.totalCount) {
225+
this.fetchItems()
226+
} else {
227+
this.resetPreselectedOptionValue()
228+
}
225229
return
226230
}
227231
if (Array.isArray(this.preselectedOptionValue) && this.preselectedOptionValue.length > 1) {

0 commit comments

Comments
 (0)