diff options
Diffstat (limited to 'main_background.js')
-rw-r--r-- | main_background.js | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/main_background.js b/main_background.js index 4442c6d..8060ebd 100644 --- a/main_background.js +++ b/main_background.js @@ -22,10 +22,9 @@ var acorn = require('acorn'); var acornLoose = require('acorn-loose'); -var jssha = require('jssha'); var legacy_license_lib = require("./legacy_license_check.js"); var {ResponseProcessor} = require("./bg/ResponseProcessor"); -var {Storage, ListStore} = require("./common/Storage"); +var {Storage, ListStore, hash} = require("./common/Storage"); var {ListManager} = require("./bg/ListManager"); var {ExternalLicenses} = require("./bg/ExternalLicenses"); @@ -51,16 +50,6 @@ function dbg_print(a,b){ } } -/** -* Wrapper around crypto lib -* -*/ -function hash(source){ - var shaObj = new jssha("SHA-256","TEXT") - shaObj.update(source); - return shaObj.getHash("HEX"); -} - /* NONTRIVIAL THINGS: - Fetch @@ -339,7 +328,7 @@ async function connected(p) { if (m.site) { key = ListStore.siteItem(key); } else { - key = ListStore.viewSourceItem(key) || key; + key = ListStore.inlineItem(key) || key; } await listManager[action](key); update = true; |