Fixed a bug in reddit options page

This commit is contained in:
ManeraKai 2022-02-13 22:04:44 +03:00
parent edbb327ee6
commit bbe6fcdef7
No known key found for this signature in database
GPG Key ID: 5ABC31FFD562E337
2 changed files with 6 additions and 4 deletions

View File

@ -104,8 +104,6 @@ function redirect(url, initiator, type) {
if (initiator && (instancesList.includes(initiator.origin) || targets.includes(initiator.host)))
return null;
// Do not redirect /accounts, /embeds.js, or anything other than main_frame
if (type !== "main_frame" || url.pathname.match(bypassPaths))
return 'CANCEL';

View File

@ -30,7 +30,10 @@ redditFrontendElement.addEventListener("change",
redditHelper.init().then(() => {
disableRedditElement.checked = !redditHelper.getDisableReddit();
redditFrontendElement.value = redditHelper.getRedditFrontend();
let frontend = redditHelper.getRedditFrontend();
redditFrontendElement.value = frontend;
changeFrontendsSettings(frontend);
commonHelper.processDefaultCustomInstances(
'libreddit',
@ -50,5 +53,6 @@ redditHelper.init().then(() => {
redditHelper.setTedditRedirectsChecks,
redditHelper.getTedditCustomRedirects,
redditHelper.setTedditCustomRedirects
)
);
})