fix gallery redirect, closes #72

This commit is contained in:
Nils 2023-01-03 15:09:14 +01:00 committed by GitHub
parent 7e41360e60
commit 4d86433e0f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -18,7 +18,7 @@ chrome.webRequest.onBeforeRequest.addListener(
} }
if (url.pathname.indexOf("/gallery") === 0) { if (url.pathname.indexOf("/gallery") === 0) {
return { redirectUrl: oldReddit + url.pathname.slice("/gallery".length) }; return { redirectUrl: oldReddit + '/comments' + url.pathname.slice("/gallery".length) };
} }
return { redirectUrl: oldReddit + url.pathname + url.search + url.hash }; return { redirectUrl: oldReddit + url.pathname + url.search + url.hash };