mirror of
https://github.com/kiwix/kiwix-js.git
synced 2025-09-22 12:01:15 -04:00
Fix a bug when the prefix was exactly a title of an article.
In this case, the article did not show up in the search results. Now it does.
This commit is contained in:
parent
fb21691f5e
commit
0586176312
@ -125,7 +125,7 @@ define(['zimfile', 'zimDirEntry', 'util', 'utf8'],
|
|||||||
return 1;
|
return 1;
|
||||||
else if (dirEntry.namespace > "A")
|
else if (dirEntry.namespace > "A")
|
||||||
return -1;
|
return -1;
|
||||||
return prefix < dirEntry.title ? -1 : 1;
|
return prefix <= dirEntry.title ? -1 : 1;
|
||||||
});
|
});
|
||||||
}, true).then(function(firstIndex) {
|
}, true).then(function(firstIndex) {
|
||||||
var titles = [];
|
var titles = [];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user