Skip to content
This repository has been archived by the owner on Sep 9, 2022. It is now read-only.

Commit

Permalink
To stop survey page from opening
Browse files Browse the repository at this point in the history
  • Loading branch information
uBlockAdmin committed Sep 24, 2018
1 parent cd22aaa commit 46a249e
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 16 deletions.
2 changes: 1 addition & 1 deletion platform/chromium/manifest.json
Expand Up @@ -2,7 +2,7 @@
"manifest_version": 2,

"name": "uBlock",
"version": "0.9.5.8",
"version": "0.9.5.9",

"default_locale": "en",
"description": "__MSG_extShortDesc__",
Expand Down
1 change: 0 additions & 1 deletion src/js/background.js
Expand Up @@ -106,7 +106,6 @@ return {
updateAssetsEvery: 97 * oneHour,
projectServerRoot: 'https://raw.githubusercontent.com/uBlock-LLC/uBlock/master/',
donationUrl: 'https://www.ublock.org/donate/',
surveyUrl:'https://www.ublock.org/update/',
pslPath: 'assets/thirdparties/publicsuffix.org/list/effective_tld_names.dat',

// permanent lists
Expand Down
15 changes: 1 addition & 14 deletions src/js/start.js
Expand Up @@ -208,32 +208,19 @@ var onInstalled = function() {

var firstInstall = lastVersion === '0.0.0.0';

var redirectUrl;

var appendVersionInQuery = "";

var onDataReceived = function(data) {
entries = data.stats || {userId: µBlock.stats.generateUserId(),totalPings: 0 };
vAPI.storage.set({ 'stats': entries });
vAPI.tabs.open({
url: redirectUrl+"?u=" + entries.userId + "&lg=" + navigator.language + appendVersionInQuery,
url: µBlock.donationUrl+"?u=" + entries.userId + "&lg=" + navigator.language,
select: true,
index: -1
});
}

if(!firstInstall) {
if(µBlock.stats.browserFlavor == "E" && µBlock.stats.language == "en") {
var curVersion = chrome.runtime.getManifest().version;
if(lastVersion != curVersion) {
redirectUrl = µBlock.surveyUrl;
appendVersionInQuery = "&v=" + curVersion;
vAPI.storage.get('stats',onDataReceived);
}
}
return;
}
redirectUrl = µBlock.donationUrl;
vAPI.storage.get('stats',onDataReceived);
};
vAPI.storage.get('extensionLastVersion', onVersionRead);
Expand Down

0 comments on commit 46a249e

Please sign in to comment.