1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-20 12:07:59 +01:00

Don't save storage objects while in private mode, restore them on exit.

This commit is contained in:
Kris Maglione
2009-06-28 14:37:23 -04:00
parent 3f5dd13453
commit 55164325df
10 changed files with 95 additions and 38 deletions

View File

@@ -706,16 +706,17 @@ const util = { //{{{
/**
* Array utility methods.
*/
util.Array = function Array(ary) {
util.Array = function Array_(ary) {
var obj = {
__proto__: ary,
__iterator__: function () this.iteritems(),
__noSuchMethod__: function (meth, args) {
let res = util.Array[meth].apply(null, [this.__proto__].concat(args));
let res = (util.Array[meth] || Array[meth]).apply(null, [this.__proto__].concat(args));
if (util.Array.isinstance(res))
return util.Array(res);
return res;
}
},
map: function() this.__noSuchMethod__("map", Array.slice(arguments)),
};
return obj;
}