Add remove setting api

This commit is contained in:
redhoodsu
2018-08-23 16:13:56 +08:00
parent d66e1de64a
commit 548cc9b513
13 changed files with 256 additions and 97 deletions

View File

@@ -199,6 +199,16 @@ export default class Network extends Tool {
evalCss.remove(this._style)
this.restoreXhr()
this.restoreFetch()
this._rmCfg()
}
_rmCfg() {
let cfg = this.config
let settings = this._container.get('settings')
if (!settings) return
settings.remove(cfg, 'overrideFetch').remove('Network')
}
_initCfg() {
let cfg = (this.config = Settings.createCfg('network', {