Skip to content

Commit f2de9b0

Browse files
authored
Revert "Add custom sort function to improve search matching (#574)" (#578)
This reverts commit 77ba201.
1 parent 71fa71e commit f2de9b0

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

src/services/nodeSearchService.ts

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -121,13 +121,7 @@ export class NodeSearchService {
121121
includeScore: true,
122122
threshold: 0.3,
123123
shouldSort: true,
124-
useExtendedSearch: true,
125-
// Sort by score first, then by length of the display name, then by index
126-
// https://github.com/Comfy-Org/ComfyUI_frontend/issues/562#issuecomment-2299738393
127-
sortFn: (a, b) =>
128-
Math.abs(a.score - b.score) > 0.01
129-
? a.score - b.score
130-
: a.item[1]['v']['length'] - b.item[1]['v']['length'] || a.idx - b.idx
124+
useExtendedSearch: true
131125
})
132126

133127
const filterSearchOptions = {

0 commit comments

Comments
 (0)