diff options
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/lib/extensions.js | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts/lib/extensions.js b/scripts/lib/extensions.js index b6b6beb2..499d3332 100644 --- a/scripts/lib/extensions.js +++ b/scripts/lib/extensions.js @@ -172,6 +172,18 @@ _unload(arguments[0], false); return extensions.load.apply(this, arguments); } + }, + "toggle" : { + value : function(name, c) { + if (_registered[name] !== undefined) { + _unload(name); + return false; + } + else { + extensions.load(name, c); + return true; + } + } } }); })(); |