mirror of
https://github.com/anticensority/runet-censorship-bypass.git
synced 2024-11-23 18:03:44 +03:00
Fix buggy update logic
This commit is contained in:
parent
ae930da8b3
commit
b3096c8d83
|
@ -679,13 +679,14 @@
|
|||
|
||||
console.log('Updating from', oldAntiCensorRu.version, 'to', antiCensorRu.version);
|
||||
try {
|
||||
if (window.apis.version.isLeq(oldAntiCensorRu.version, '0.0.1.57')) {
|
||||
const azWithPort = 'https://antizapret.prostovpn.org:8443/proxy.pac';
|
||||
const azWithPortAlt = 'https://antizapret.prostovpn.org:18443/proxy.pac';
|
||||
const urls = window.apis.antiCensorRu.pacProviders['Антизапрет'].pacUrls;
|
||||
urls[0] = 'https://antizapret.prostovpn.org/proxy.pac';
|
||||
urls.unshift(azWithPort, azWithPortAlt);
|
||||
console.log('Successfully updated to 0.0.1.58.');
|
||||
if (window.apis.version.isLeq(oldAntiCensorRu.version, '0.0.1.59')) {
|
||||
window.apis.antiCensorRu.pacProviders['Антизапрет'].pacUrls = [
|
||||
'https://antizapret.prostovpn.org:8443/proxy.pac',
|
||||
'https://antizapret.prostovpn.org:18443/proxy.pac',
|
||||
'https://antizapret.prostovpn.org/proxy.pac',
|
||||
'https://rebrand.ly/ac-antizapret-pac',
|
||||
];
|
||||
console.log('Successfully updated to 0.0.1.60.');
|
||||
}
|
||||
} catch (e) {
|
||||
// Log update error.
|
||||
|
|
Loading…
Reference in New Issue
Block a user