mirror of
https://github.com/frappe/books.git
synced 2024-11-09 23:30:56 +00:00
fix: prevent e is not iterable
This commit is contained in:
parent
2c1c4aedf8
commit
b7810ee25e
@ -523,7 +523,12 @@ export class Search {
|
||||
keys.sort((a, b) => parseFloat(b) - parseFloat(a));
|
||||
const array: SearchItems = [];
|
||||
for (const key of keys) {
|
||||
this._pushDocSearchItems(groupedKeywords[key], array, input);
|
||||
const keywords = groupedKeywords[key];
|
||||
if (!keywords?.length) {
|
||||
continue;
|
||||
}
|
||||
|
||||
this._pushDocSearchItems(keywords, array, input);
|
||||
if (key === '0') {
|
||||
this._pushNonDocSearchItems(array, input);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user