Make searchtools.js support old searchindex.js files
Sphinx 4.3 has changed format of searchindex.js files, but in Debian there are lots of packages built with older Sphinx, and we want to keep them working for some time. Forwarded: not-needed Gbp-Pq: Name support_old_search_indexes.diff
This commit is contained in:
parent
f0e8f8ab62
commit
bd3017c63b
|
@ -328,6 +328,9 @@ var Search = {
|
|||
var results = [];
|
||||
|
||||
for (var prefix in objects) {
|
||||
if (!(objects[prefix] instanceof Array)) {
|
||||
objects[prefix] = Object.entries(objects[prefix]).map(([name, match]) => [...match, name]);
|
||||
}
|
||||
for (var iMatch = 0; iMatch != objects[prefix].length; ++iMatch) {
|
||||
var match = objects[prefix][iMatch];
|
||||
var name = match[4];
|
||||
|
|
Loading…
Reference in New Issue