dont install on non-canary

This commit is contained in:
Astra 2018-05-15 17:31:56 -04:00
parent 6b48b356e9
commit 71e5fc54ad
1 changed files with 7 additions and 1 deletions

View File

@ -156,9 +156,9 @@
window.Buffer = require("buffer").Buffer;
var data = electron.app.getPath('userData');
var branch = require('path').basename(data).substr(7);
function load() {
var branch = require('path').basename(data).substr(7);
electron.BrowserWindow.addExtension(data + '/crxpwn');
electron.getCurrentWindow().loadURL('https://' + (branch && branch != 'development' ? branch + '.' : '') + 'discordapp.com/channels/@me');
}
@ -168,6 +168,12 @@
load();
}
// temporary
if (branch != 'canary') {
alert('EndPwn3.1 Staging uses crxpwn which only works on Canary at the moment', 'Sorry');
load();
}
// asarpwn (as a removal tool)
function asarinject(sig, inj) {
var dirlisting = fs.readdirSync(data);