Reverse search results when re-ordering

Ensuring higher results are re-ordered to the top last
pull/659/head
Kevin Payravi 2024-04-27 20:22:28 -04:00
parent d7fcc1d172
commit 84892bf478
1 changed files with 4 additions and 0 deletions

View File

@ -549,6 +549,10 @@ async function reorderSearchResults(searchResults, searchEngine, storage) {
let crossLanguageSetting = storage.crossLanguage || 'off';
// Re-order search results
// This is so that higher results are re-ordered to the top last
searchResults = searchResults.reverse();
for (const searchResult of searchResults) {
try {
if (searchResult.closest('.iwb-detected')) {