diff options
author | Robbie Langer | 2018-06-03 09:09:08 -0400 |
---|---|---|
committer | Robbie Langer | 2018-06-03 09:09:08 -0400 |
commit | e9a6cc467f566228921c8f8eb76613821e70d451 (patch) | |
tree | d77acb8460b40f8b1a59384f2d486e3e9f1701b3 | |
parent | c93f073d1da3b08ebc45effdabc91c965a78c5e0 (diff) |
replaced loadJS with builtin $loader.script
-rw-r--r-- | install.js | 13 |
1 files changed, 2 insertions, 11 deletions
@@ -1,18 +1,9 @@ -var _main = `function loadJS (source, onready){ - var sc = document.createElement("script"); - sc.src = source; - sc.type = "text/javascript"; - if (onready) sc.addEventListener("load", onready); - document.head.appendChild(sc); - return sc; -} - -var interval = setInterval(function () { +var _main = `var interval = setInterval(function () { try { if (!!le) { localStorage[".pkg93/userscript"] = ""; clearInterval(interval); - loadJS("https://rawgit.com/pkg93/pkg93/master/pkg93.js", function () {}); + $loader.script("https://rawgit.com/pkg93/pkg93/master/pkg93.js"; } } catch (err) { console.error(err); |