mirror of
https://github.com/davegallant/rfd-redirect-stripper.git
synced 2025-08-05 16:23:40 +00:00
23 lines
522 B
JavaScript
23 lines
522 B
JavaScript
function updateRedirects() {
|
|
browser.storage.local.get("config", function (URL) {
|
|
fetch(URL.config)
|
|
.then((res) => res.json())
|
|
.then((res) => {
|
|
browser.storage.local
|
|
.set({
|
|
redirects: res,
|
|
})
|
|
.catch((error) => {
|
|
console.log(error);
|
|
});
|
|
});
|
|
});
|
|
}
|
|
|
|
function setDefaultConfig() {
|
|
browser.storage.local.set({
|
|
config:
|
|
"https://raw.githubusercontent.com/davegallant/rfd-redirect-stripper/main/redirects.json",
|
|
});
|
|
}
|