MCPcopy Create free account
hub / github.com/Useful-Scripts-Extension/useful-script / toggle

Function toggle

popup/helpers/storageScripts.js:28–32  ·  view source on GitHub ↗
(script)

Source from the content-addressed store, hash-verified

26 console.log("removed ", script);
27 };
28 const toggle = (script) => {
29 let exist = has(script);
30 if (exist) remove(script);
31 else add(script);
32 };
33 const clear = () => {
34 localStorage.setItem(key, "[]");
35 };

Callers

nothing calls this directly

Calls 3

hasFunction · 0.70
removeFunction · 0.70
addFunction · 0.70

Tested by

no test coverage detected