aboutsummaryrefslogtreecommitdiff
path: root/src/nintendo-com-fix-support
diff options
context:
space:
mode:
authorWojtek Kosior <koszko@koszko.org>2022-06-28 21:09:19 +0200
committerWojtek Kosior <koszko@koszko.org>2022-06-30 12:33:08 +0200
commit6735fa554d83adc3d527329779eb4e2afc470ede (patch)
treeccfdcdb4be72384d1b2fb6477021a2e30eb9803c /src/nintendo-com-fix-support
parent70022b58d156ca58ff7cb53a4a0c1f111d161403 (diff)
downloadhydrilla-fixes-bundle-6735fa554d83adc3d527329779eb4e2afc470ede.tar.gz
hydrilla-fixes-bundle-6735fa554d83adc3d527329779eb4e2afc470ede.zip
correct search pages navigation in the Nintendo Support fix
Diffstat (limited to 'src/nintendo-com-fix-support')
-rw-r--r--src/nintendo-com-fix-support/nintendo.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/nintendo-com-fix-support/nintendo.js b/src/nintendo-com-fix-support/nintendo.js
index 218789f..c890474 100644
--- a/src/nintendo-com-fix-support/nintendo.js
+++ b/src/nintendo-com-fix-support/nintendo.js
@@ -104,5 +104,7 @@ for (const results_page_link of
document.querySelectorAll('[href^="/app/answers/list/page/"]')) {
const page_nr = /[0-9]*$/.exec(results_page_link.href);
const current_path = window.location.pathname;
- results_page_link.href = current_path.replace(/[0-9]*$/, page_nr);
+ results_page_link.href = current_path
+ .replace("list/kw", "list/st/5/kw")
+ .replace(/(search|page)\/[0-9]*$/, `page/${page_nr}`);
}