Skip to content

Commit

Permalink
Fix rate-limiting when setting options from options page
Browse files Browse the repository at this point in the history
  • Loading branch information
ajayyy committed Mar 7, 2024
1 parent eabc0a8 commit 5b4a5fa
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ async function init() {
break;
case "resetToDefault":
Config.resetToDefault();
window.location.reload();
setTimeout(() => window.location.reload(), 200);
break;
}
});
Expand Down Expand Up @@ -621,8 +621,7 @@ async function setTextOption(option: string, element: HTMLElement, value: string
await invidiousOnClick(checkbox, "supportInvidious");
}

window.location.reload();

setTimeout(() => window.location.reload(), 200);
} catch (e) {
alert(chrome.i18n.getMessage("incorrectlyFormattedOptions"));
}
Expand Down

0 comments on commit 5b4a5fa

Please sign in to comment.