From 8ca0470e02cd1efffd8a165b56eb6fa2974dfbca Mon Sep 17 00:00:00 2001 From: Handle Date: Thu, 28 Mar 2019 14:08:21 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E8=BF=9B=EF=BC=9A=E4=BF=AE=E6=AD=A3?= =?UTF-8?q?=E9=83=A8=E5=88=86=E6=8B=BC=E5=86=99=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bin/main/mainLoader.js | 2 +- manager/Ping.js | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/bin/main/mainLoader.js b/bin/main/mainLoader.js index c5be473..e7bcdc2 100644 --- a/bin/main/mainLoader.js +++ b/bin/main/mainLoader.js @@ -131,7 +131,7 @@ const prebuildExecuteCode = executeScriptInfo => { if (prop === "localStorage" && ${!!executePreferences.localStorage} === false) { return undefined } - if (prop === "XMLHttpRequest" && ${!!executePreferences.XMLHTTPRequest} === false) { + if (prop === "XMLHttpRequest" && ${!!executePreferences.XMLHttpRequest} === false) { return undefined } if (prop === "WebSocket" && ${!!executePreferences.WebSocket} === false) { diff --git a/manager/Ping.js b/manager/Ping.js index 9675622..cbd3786 100644 --- a/manager/Ping.js +++ b/manager/Ping.js @@ -63,7 +63,7 @@ class Ping { _getService () { if (!this.services) return Promise.reject(new Error('services is null')) - const choseService = localStorage.getItem('choseService') + const choseService = window.localStorage.getItem('choseService') if (choseService) { this.currentService = this.serviceList.find(service => service === choseService) || @@ -110,6 +110,7 @@ class Ping { }) } + // 这个函数没有被使用 _renderError (err) { console.error(err) const serverTextDom = document.getElementById('serverText')