Fixed small things. apparently Fixed Instances got fixed #337
This commit is contained in:
parent
7b6bc78f41
commit
4c4c47e82f
|
@ -133,7 +133,7 @@ function initDefaults() {
|
|||
let dataJson = JSON.parse(data);
|
||||
redirects.libremdb = dataJson.libremdb;
|
||||
browser.storage.local.set({
|
||||
disableImdb: false,
|
||||
disableImdb: true,
|
||||
imdbProtocol: "normal",
|
||||
|
||||
imdbRedirects: redirects,
|
||||
|
|
|
@ -8,7 +8,7 @@ const targets = /^https?:\/{2}(((www|maps)\.)?(google\.).*(\/maps)|maps\.(google
|
|||
let redirects = {
|
||||
'osm': {
|
||||
"normal": [
|
||||
"https://openstreetmap.org"
|
||||
"https://www.openstreetmap.org"
|
||||
]
|
||||
},
|
||||
'facil': {
|
||||
|
|
|
@ -86,7 +86,7 @@ function redirect(url, type, initiator) {
|
|||
function initDefaults() {
|
||||
return new Promise(resolve => {
|
||||
browser.storage.local.set({
|
||||
disableReuters: false,
|
||||
disableReuters: true,
|
||||
reutersProtocol: "normal",
|
||||
|
||||
reutersRedirects: redirects,
|
||||
|
|
|
@ -49,7 +49,7 @@ function updateInstances() {
|
|||
searchHelper.setRedirects({ 'searx': instances.searx, 'searxng': instances.searxng, 'whoogle': instances.whoogle });
|
||||
wikipediaHelper.setRedirects(instances.wikiless);
|
||||
mediumHelper.setRedirects(instances.scribe);
|
||||
quoraHelper.setRedirects(instances.query);
|
||||
quoraHelper.setRedirects(instances.quetre);
|
||||
libremdbHelper.setRedirects(instances.libremdb);
|
||||
sendTargetsHelper.setRedirects(instances.send);
|
||||
tiktokHelper.setRedirects(instances.proxiTok);
|
||||
|
|
|
@ -1,49 +0,0 @@
|
|||
[
|
||||
"https://invidious.kavin.rocks",
|
||||
"https://invidious.lunar.icu",
|
||||
"https://piped.kavin.rocks",
|
||||
"https://piped.tokhmi.xyz",
|
||||
"https://piped.moomoo.me",
|
||||
"https://piped.syncpundit.com",
|
||||
"https://piped.mha.fi",
|
||||
"https://piped.shimul.me",
|
||||
"https://nitter.nixnet.services",
|
||||
"https://nitter.domain.glass",
|
||||
"https://birdsite.xanny.family",
|
||||
"https://nitter.moomoo.me",
|
||||
"https://notabird.site",
|
||||
"https://fuckthesacklers.network",
|
||||
"https://nitter.govt.land",
|
||||
"https://nitter.winscloud.net",
|
||||
"https://twtr.bch.bar",
|
||||
"https://nitter.lunar.icu",
|
||||
"https://twitter.dr460nf1r3.org",
|
||||
"https://bib.actionsack.com",
|
||||
"https://libreddit.domain.glass",
|
||||
"https://r.nf",
|
||||
"https://libreddit.flux.industries",
|
||||
"https://lr.oversold.host",
|
||||
"https://libreddit.hu",
|
||||
"https://lr.stilic.ml",
|
||||
"https://reddi.tk",
|
||||
"https://r.walkx.org",
|
||||
"https://libreddit.yonalee.eu",
|
||||
"https://libreddit.winscloud.net",
|
||||
"https://libreddit.lunar.icu",
|
||||
"https://r.ahwx.org",
|
||||
"https://reddit.dr460nf1r3.org",
|
||||
"https://teddit.domain.glass",
|
||||
"https://wiki.604kph.xyz",
|
||||
"https://wikiless.lunar.icu",
|
||||
"https://lingva.lunar.icu",
|
||||
"https://searx.josie.lol",
|
||||
"https://searx.org",
|
||||
"https://searx.run",
|
||||
"https://searx.albony.xyz",
|
||||
"https://search.albony.xyz",
|
||||
"https://search.garudalinux.org",
|
||||
"https://search.dr460nf1r3.org",
|
||||
"https://whoogle.lunar.icu",
|
||||
"https://rimgo.lunar.icu",
|
||||
"https://i.actionsack.com"
|
||||
]
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "__MSG_extensionName__",
|
||||
"description": "__MSG_extensionDescription__",
|
||||
"version": "2.1.0",
|
||||
"version": "2.2.0",
|
||||
"manifest_version": 2,
|
||||
"browser_specific_settings": {
|
||||
"gecko": {
|
||||
|
|
|
@ -31,7 +31,6 @@ browser.runtime.onInstalled.addListener(
|
|||
fetch('/instances/blacklist.json').then(response => response.text()).then(async data => {
|
||||
browser.storage.local.clear(
|
||||
() => {
|
||||
|
||||
browser.storage.local.set({ cloudflareBlackList: JSON.parse(data).cloudflare },
|
||||
() => {
|
||||
browser.storage.local.set({ authenticateBlackList: JSON.parse(data).authenticate },
|
||||
|
@ -60,6 +59,10 @@ browser.runtime.onInstalled.addListener(
|
|||
});
|
||||
})
|
||||
};
|
||||
function initDefault(){
|
||||
|
||||
}
|
||||
|
||||
// if (details.reason == 'install') {
|
||||
if (details.reason == 'install' || (details.reason == "update" && details.previousVersion != browser.runtime.getManifest().version)) {
|
||||
if (details.reason == "update")
|
||||
|
|
|
@ -16,6 +16,7 @@ import wikipediaHelper from "../../../assets/javascripts/wikipedia.js";
|
|||
import mediumHelper from "../../../assets/javascripts/medium.js";
|
||||
import quoraHelper from "../../../assets/javascripts/quora.js";
|
||||
import libremdbHelper from "../../../assets/javascripts/imdb.js";
|
||||
import reutersHelper from "../../../assets/javascripts/reuters.js";
|
||||
import imgurHelper from "../../../assets/javascripts/imgur.js";
|
||||
import tiktokHelper from "../../../assets/javascripts/tiktok.js";
|
||||
import sendTargetsHelper from "../../../assets/javascripts/sendTargets.js";
|
||||
|
@ -23,14 +24,12 @@ import peertubeHelper from "../../../assets/javascripts/peertube.js";
|
|||
import lbryHelper from "../../../assets/javascripts/lbry.js";
|
||||
|
||||
let updateInstancesElement = document.getElementById("update-instances");
|
||||
updateInstancesElement.addEventListener("click", () => {
|
||||
updateInstancesElement.addEventListener("click", async () => {
|
||||
let oldHtml = updateInstancesElement.innerHTML
|
||||
updateInstancesElement.innerHTML = '...';
|
||||
if (utils.updateInstances()) {
|
||||
updateInstancesElement.innerHTML = 'Done!';
|
||||
new Promise(resolve => setTimeout(resolve, 1500)).then( // sleep 1500ms
|
||||
() => updateInstancesElement.innerHTML = oldHtml
|
||||
)
|
||||
if (await utils.updateInstances()) {
|
||||
updateInstancesElement.innerHTML = oldHtml;
|
||||
location.reload();
|
||||
}
|
||||
else
|
||||
updateInstancesElement.innerHTML = 'Failed Miserabely';
|
||||
|
|
Loading…
Reference in New Issue