object.database
Advanced tools
Comparing version 1.8.0 to 1.8.1
@@ -1,2 +0,2 @@ | ||
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.ObjectDatabase=t():e.ObjectDatabase=t()}(global,function(){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var u=t[n]={i:n,l:!1,exports:{}};return e[n].call(u.exports,u,u.exports,r),u.l=!0,u.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var u in e)r.d(n,u,function(t){return e[t]}.bind(null,u));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=19)}([function(e,t){e.exports=require("babel-runtime/helpers/asyncToGenerator")},function(e,t){e.exports=require("babel-runtime/regenerator")},function(e,t){e.exports=require("babel-runtime/helpers/classCallCheck")},function(e,t){e.exports=require("babel-runtime/helpers/createClass")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=s(r(16)).default,u=s(r(1)).default,a=s(r(0)).default,o=s(r(2)).default,i=s(r(3)).default;function s(e){return e&&e.__esModule?e:{default:e}}var c=function(){function e(){o(this,e),this.memory={}}return i(e,[{key:"get",value:function(){var e=a(u.mark(function e(t){return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"set",value:function(){var e=a(u.mark(function e(t,r){return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}},e,this)}));return function(t,r){return e.apply(this,arguments)}}()},{key:"del",value:function(){var e=a(u.mark(function e(t){return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"_fetch",value:function(){var e=a(u.mark(function e(t){var r;return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.get(t);case 2:if(void 0!==(r=e.sent)){e.next=5;break}return e.abrupt("return");case 5:if("string"==typeof r){e.next=7;break}return e.abrupt("return");case 7:return this.memory[t]=JSON.parse(r),e.abrupt("return",this._get(t));case 9:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"_get",value:function(e){return this.memory[e]}},{key:"_set",value:function(e,t){var r=this,o=this.memory[e];this.memory[e]=t,a(u.mark(function a(){return u.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return u.prev=0,t=n(t),u.next=4,r.set(e,t);case 4:u.next=10;break;case 6:u.prev=6,u.t0=u.catch(0),r.memory[e]=o,console.error(u.t0);case 10:case"end":return u.stop()}},a,r,[[0,6]])}))()}},{key:"_del",value:function(e){var t=this,r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=this.memory[e];this.memory[e]=void 0,r&&a(u.mark(function r(){return u.wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,t.del(e);case 3:r.next=9;break;case 5:r.prev=5,r.t0=r.catch(0),t.memory[e]=n,console.error(r.t0);case 9:case"end":return r.stop()}},r,t,[[0,5]])}))()}}]),e}();t.default=c},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n,u=r(2),a=(n=u,n&&n.__esModule?n:{default:n}).default;t.default=function e(t,r){a(this,e),this.storage=r,this.namespace=t}},function(e,t){e.exports=require("babel-runtime/core-js/get-iterator")},function(e,t){e.exports=require("babel-runtime/helpers/typeof")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=s(r(7)).default,u=s(r(1)).default,a=s(r(6)).default,o=s(r(0)).default,i=s(r(5)).default;function s(e){return e&&e.__esModule?e:{default:e}}var c,f,l=(c=o(u.mark(function e(t,r,n){var o,s,c,f,l,d,v,h,g,b=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return o=t+".o",e.next=3,r._fetch(o);case 3:if(s=e.sent,c=new i(t,r),void 0===s){e.next=32;break}f=!0,l=!1,d=void 0,e.prev=9,v=a(s);case 11:if(f=(h=v.next()).done){e.next=18;break}return g=h.value,e.next=15,p(c,g,n,b);case 15:f=!0,e.next=11;break;case 18:e.next=24;break;case 20:e.prev=20,e.t0=e.catch(9),l=!0,d=e.t0;case 24:e.prev=24,e.prev=25,!f&&v.return&&v.return();case 27:if(e.prev=27,!l){e.next=30;break}throw d;case 30:return e.finish(27);case 31:return e.finish(24);case 32:case"end":return e.stop()}},e,void 0,[[9,20,24,32],[25,,27,31]])})),function(e,t,r){return c.apply(this,arguments)}),p=(f=o(u.mark(function e(t,r,a,o){var i,s,c,f,p,d;return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=t.namespace+".p."+r,s=i+".o",c=t.storage._get(i),f=t.storage._get(s),e.next=6,t.storage._fetch(i);case 6:return p=e.sent,e.next=9,t.storage._fetch(s);case 9:if(d=e.sent,!0!==o[i]){e.next=14;break}return e.abrupt("return");case 14:o[i]=!0;case 15:if(void 0===d){e.next=18;break}return e.next=18,l(i,t.storage,a,o);case 18:if("object"!==(void 0===p?"undefined":n(p))){e.next=21;break}return e.next=21,l(p.ref,t.storage,a,o);case 21:void 0===d&&void 0!==f&&a(t,r),void 0===p&&void 0!==c&&a(t,r);case 23:case"end":return e.stop()}},e,void 0)})),function(e,t,r,n){return f.apply(this,arguments)});t.default=l},function(e,t){e.exports=require("fs")},function(e,t){e.exports=require("node-localstorage")},function(e,t){e.exports=require("babel-runtime/helpers/inherits")},function(e,t){e.exports=require("babel-runtime/helpers/possibleConstructorReturn")},function(e,t){e.exports=require("babel-runtime/core-js/object/get-prototype-of")},function(e,t){e.exports=require("babel-runtime/core-js/promise")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=v(r(1)).default,u=v(r(14)).default,a=v(r(0)).default,o=v(r(13)).default,i=v(r(2)).default,s=v(r(3)).default,c=v(r(12)).default,f=v(r(11)).default,l=v(r(10)).default,p=v(r(4)).default,d=v(r(9)).default;function v(e){return e&&e.__esModule?e:{default:e}}var h=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"localStorage",r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:5;i(this,t);var n=c(this,(t.__proto__||o(t)).call(this));return n.storageName=e,"localStorage"!==e||"undefined"==typeof localStorage||null===localStorage?n.surrogate=new l.LocalStorage(e,1024*r*1024):n.surrogate=localStorage,n}return f(t,p),s(t,[{key:"get",value:function(){var e=a(n.mark(function e(t){var r=this;return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",new u(function(e){d.readFile("./"+r.storageName+"/"+t,"utf8",function(t,r){e(r)})}));case 1:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"set",value:function(){var e=a(n.mark(function e(t,r){return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:this.surrogate.setItem(t,r);case 1:case"end":return e.stop()}},e,this)}));return function(t,r){return e.apply(this,arguments)}}()},{key:"del",value:function(){var e=a(n.mark(function e(t){return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:this.surrogate.removeItem(t);case 1:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()}]),t}();t.default=h},function(e,t){e.exports=require("babel-runtime/core-js/json/stringify")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=c(r(1)).default,u=c(r(0)).default,a=c(r(6)).default,o=c(r(7)).default,i=c(r(8)).default,s=c(r(5)).default;function c(e){return e&&e.__esModule?e:{default:e}}var f,l=function(e,t){var r=new s(e,t),n=r.namespace+".o";void 0===r.storage._get(n)&&r.storage._set(n,[]);var u=new Proxy(r,{defineProperty:function(e,t,r){return p(e,t,r)},set:function(e,t,r){return p(e,t,r)},get:function(e,t){return d(e,t)},deleteProperty:function(e,t){return v(e,t)},enumerate:function(e){return _(e)},ownKeys:function(e){return _(e)},has:function(e,t){return m(e,t)},getOwnPropertyDescriptor:function(e,t){return x(e,t)}});return r.__proxy=u,u},p=function(e,t,r){return"then"!==t&&("clear"!==t&&("update"!==t&&("__self"!==t&&(void 0===r||null===r?h(e,t):g(e,t,r),!0))))},d=function(e,t){if("then"!==t){if("clear"===t)return function(){return b(e)};if("update"===t)return function(){return y(e)};if("__self"===t)return e;var r=e.namespace+".p."+t,n=r+".o",u=e.storage._get(n),a=e.storage._get(r);return void 0!==u?l(r,e.storage):"object"===(void 0===a?"undefined":o(a))?l(a.ref,e.storage):a}},v=function(e,t){return"then"!==t&&("clear"!==t&&("update"!==t&&("__self"!==t&&(h(e,t),!0))))},h=function(e,t,r){var n=e.namespace+".o",u=e.storage._get(n),o=u||[],i=e.namespace+".p."+t,s=i+".o",c=e.storage._get(s);if(c){var f=l(i,e.storage),p=!0,d=!1,v=void 0;try{for(var h,g=a(c);!(p=(h=g.next()).done);p=!0){f[h.value]=void 0}}catch(e){d=!0,v=e}finally{try{!p&&g.return&&g.return()}finally{if(d)throw v}}e.storage._del(s,r)}else e.storage._del(i,r);o=o.filter(function(e){return e!==t}),e.storage._set(n,o)},g=function(e,t,r){h(e,t);var n=e.namespace+".o",u=e.storage._get(n),a=u||[],i=e.namespace+".p."+t;if(r instanceof s){if(r.__self.storage!==e.storage)throw new Error("Cannot cross Storages");var c={ref:r.__self.namespace};e.storage._set(i,c)}else if("object"===(void 0===r?"undefined":o(r))){var f=l(i,e.storage);for(var p in r)r.hasOwnProperty(p)&&(f[p]=r[p])}else e.storage._set(i,r);a.push(t),e.storage._set(n,a)},b=function(e){var t=e.namespace+".o",r=e.storage._get(t),n=!0,u=!1,o=void 0;try{for(var i,s=a(r);!(n=(i=s.next()).done);n=!0){var c=i.value;h(e,c)}}catch(e){u=!0,o=e}finally{try{!n&&s.return&&s.return()}finally{if(u)throw o}}},y=(f=u(n.mark(function e(t){return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,i(t.namespace,t.storage,function(e,t){h(e,t,!1)});case 2:case"end":return e.stop()}},e,void 0)})),function(e){return f.apply(this,arguments)}),m=function(e,t){var r=e.namespace+".o";return e.storage._get(r).includes(t)},_=function(e){var t=e.namespace+".o";return e.storage._get(t)},x=function(e,t){var r=d(e,t);return r?{value:r,writable:!0,enumerable:!0,configurable:!0}:void 0};t.default=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=i(r(1)).default,u=i(r(0)).default,a=i(r(8)).default,o=i(r(17)).default;function i(e){return e&&e.__esModule?e:{default:e}}var s,c=(s=u(n.mark(function e(t,r){return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a(t,r);case 2:return e.abrupt("return",o(t,r));case 3:case"end":return e.stop()}},e,void 0)})),function(e,t){return s.apply(this,arguments)});t.default=c},function(e,t,r){"use strict";var n=r(18).default,u=r(4).default,a=r(15).default;e.exports={ObjectDB:n,Storage:u,LocalStorage:a}}])}); | ||
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.ObjectDatabase=t():e.ObjectDatabase=t()}(global,function(){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var u=t[n]={i:n,l:!1,exports:{}};return e[n].call(u.exports,u,u.exports,r),u.l=!0,u.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var u in e)r.d(n,u,function(t){return e[t]}.bind(null,u));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=18)}([function(e,t){e.exports=require("babel-runtime/helpers/asyncToGenerator")},function(e,t){e.exports=require("babel-runtime/regenerator")},function(e,t){e.exports=require("babel-runtime/helpers/classCallCheck")},function(e,t){e.exports=require("babel-runtime/helpers/createClass")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=s(r(15)).default,u=s(r(1)).default,a=s(r(0)).default,o=s(r(2)).default,i=s(r(3)).default;function s(e){return e&&e.__esModule?e:{default:e}}var c=function(){function e(){o(this,e),this.memory={}}return i(e,[{key:"get",value:function(){var e=a(u.mark(function e(t){return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"set",value:function(){var e=a(u.mark(function e(t,r){return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}},e,this)}));return function(t,r){return e.apply(this,arguments)}}()},{key:"del",value:function(){var e=a(u.mark(function e(t){return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"_fetch",value:function(){var e=a(u.mark(function e(t){var r;return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.get(t);case 2:if(void 0!==(r=e.sent)){e.next=5;break}return e.abrupt("return");case 5:if("string"==typeof r){e.next=7;break}return e.abrupt("return");case 7:return this.memory[t]=JSON.parse(r),e.abrupt("return",this._get(t));case 9:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"_get",value:function(e){return this.memory[e]}},{key:"_set",value:function(e,t){var r=this,o=this.memory[e];this.memory[e]=t,a(u.mark(function a(){return u.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return u.prev=0,t=n(t),u.next=4,r.set(e,t);case 4:u.next=10;break;case 6:u.prev=6,u.t0=u.catch(0),r.memory[e]=o,console.error(u.t0);case 10:case"end":return u.stop()}},a,r,[[0,6]])}))()}},{key:"_del",value:function(e){var t=this,r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=this.memory[e];this.memory[e]=void 0,r&&a(u.mark(function r(){return u.wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,t.del(e);case 3:r.next=9;break;case 5:r.prev=5,r.t0=r.catch(0),t.memory[e]=n,console.error(r.t0);case 9:case"end":return r.stop()}},r,t,[[0,5]])}))()}}]),e}();t.default=c},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n,u=r(2),a=(n=u,n&&n.__esModule?n:{default:n}).default;t.default=function e(t,r){a(this,e),this.storage=r,this.namespace=t}},function(e,t){e.exports=require("babel-runtime/core-js/get-iterator")},function(e,t){e.exports=require("babel-runtime/helpers/typeof")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=s(r(7)).default,u=s(r(1)).default,a=s(r(6)).default,o=s(r(0)).default,i=s(r(5)).default;function s(e){return e&&e.__esModule?e:{default:e}}var c,f,l=(c=o(u.mark(function e(t,r,n){var o,s,c,f,l,d,v,h,b,m=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return o=t+".o",e.next=3,r._fetch(o);case 3:if(s=e.sent,c=new i(t,r),void 0===s){e.next=32;break}f=!0,l=!1,d=void 0,e.prev=9,v=a(s);case 11:if(f=(h=v.next()).done){e.next=18;break}return b=h.value,e.next=15,p(c,b,n,m);case 15:f=!0,e.next=11;break;case 18:e.next=24;break;case 20:e.prev=20,e.t0=e.catch(9),l=!0,d=e.t0;case 24:e.prev=24,e.prev=25,!f&&v.return&&v.return();case 27:if(e.prev=27,!l){e.next=30;break}throw d;case 30:return e.finish(27);case 31:return e.finish(24);case 32:case"end":return e.stop()}},e,void 0,[[9,20,24,32],[25,,27,31]])})),function(e,t,r){return c.apply(this,arguments)}),p=(f=o(u.mark(function e(t,r,a,o){var i,s,c,f,p,d;return u.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=t.namespace+".p."+r,s=i+".o",c=t.storage._get(i),f=t.storage._get(s),e.next=6,t.storage._fetch(i);case 6:return p=e.sent,e.next=9,t.storage._fetch(s);case 9:if(d=e.sent,!0!==o[i]){e.next=14;break}return e.abrupt("return");case 14:o[i]=!0;case 15:if(void 0===d){e.next=18;break}return e.next=18,l(i,t.storage,a,o);case 18:if("object"!==(void 0===p?"undefined":n(p))){e.next=21;break}return e.next=21,l(p.ref,t.storage,a,o);case 21:void 0===d&&void 0!==f&&a(t,r),void 0===p&&void 0!==c&&a(t,r);case 23:case"end":return e.stop()}},e,void 0)})),function(e,t,r,n){return f.apply(this,arguments)});t.default=l},function(e,t){e.exports=require("fs")},function(e,t){e.exports=require("babel-runtime/helpers/inherits")},function(e,t){e.exports=require("babel-runtime/helpers/possibleConstructorReturn")},function(e,t){e.exports=require("babel-runtime/core-js/object/get-prototype-of")},function(e,t){e.exports=require("babel-runtime/core-js/promise")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=d(r(1)).default,u=d(r(13)).default,a=d(r(0)).default,o=d(r(12)).default,i=d(r(2)).default,s=d(r(3)).default,c=d(r(11)).default,f=d(r(10)).default,l=d(r(4)).default,p=d(r(9)).default;function d(e){return e&&e.__esModule?e:{default:e}}var v,h,b=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"localStorage";i(this,t);var r=c(this,(t.__proto__||o(t)).call(this));return r.storageName=e,r.folderCreated=g("./"+r.storageName+"/"),r}return f(t,l),s(t,[{key:"get",value:function(){var e=a(n.mark(function e(t){var r=this;return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.folderCreated;case 2:return e.abrupt("return",new u(function(e){p.readFile("./"+r.storageName+"/"+t,"utf8",function(t,r){e(r)})}));case 3:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"set",value:function(){var e=a(n.mark(function e(t,r){var a=this;return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.folderCreated;case 2:return e.abrupt("return",new u(function(e){p.writeFile("./"+a.storageName+"/"+t,r,function(t){if(t)throw t;e()})}));case 3:case"end":return e.stop()}},e,this)}));return function(t,r){return e.apply(this,arguments)}}()},{key:"del",value:function(){var e=a(n.mark(function e(t){var r=this;return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.folderCreated;case 2:return e.abrupt("return",new u(function(e){p.unlink("./"+r.storageName+"/"+t,function(t){e()})}));case 3:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()}]),t}(),m=(v=a(n.mark(function e(t){return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",new u(function(e){p.exists(""+t,function(t){e(t)})}));case 1:case"end":return e.stop()}},e,void 0)})),function(e){return v.apply(this,arguments)}),g=(h=a(n.mark(function e(t){return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,m(t);case 2:if(!1!==e.sent){e.next=5;break}return e.abrupt("return",new u(function(e){p.mkdir(""+t,function(t){e()})}));case 5:case"end":return e.stop()}},e,void 0)})),function(e){return h.apply(this,arguments)});t.default=b},function(e,t){e.exports=require("babel-runtime/core-js/json/stringify")},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=c(r(1)).default,u=c(r(0)).default,a=c(r(6)).default,o=c(r(7)).default,i=c(r(8)).default,s=c(r(5)).default;function c(e){return e&&e.__esModule?e:{default:e}}var f,l=function(e,t){var r=new s(e,t),n=r.namespace+".o";return void 0===r.storage._get(n)&&r.storage._set(n,[]),new Proxy(r,{defineProperty:function(e,t,r){return p(e,t,r)},set:function(e,t,r){return p(e,t,r)},get:function(e,t){return d(e,t)},deleteProperty:function(e,t){return v(e,t)},enumerate:function(e){return x(e)},ownKeys:function(e){return x(e)},has:function(e,t){return y(e,t)},getOwnPropertyDescriptor:function(e,t){return _(e,t)}})},p=function(e,t,r){return"then"!==t&&("clear"!==t&&("update"!==t&&("__self"!==t&&(void 0===r||null===r?h(e,t):b(e,t,r),!0))))},d=function(e,t){if("then"!==t){if("clear"===t)return function(){return m(e)};if("update"===t)return function(){return g(e)};if("__self"===t)return e;var r=e.namespace+".p."+t,n=r+".o",u=e.storage._get(n),a=e.storage._get(r);return void 0!==u?l(r,e.storage):"object"===(void 0===a?"undefined":o(a))?l(a.ref,e.storage):a}},v=function(e,t){return"then"!==t&&("clear"!==t&&("update"!==t&&("__self"!==t&&(h(e,t),!0))))},h=function(e,t,r){var n=e.namespace+".o",u=e.storage._get(n),o=u||[],i=e.namespace+".p."+t,s=i+".o",c=e.storage._get(s);if(c){var f=l(i,e.storage),p=!0,d=!1,v=void 0;try{for(var h,b=a(c);!(p=(h=b.next()).done);p=!0){f[h.value]=void 0}}catch(e){d=!0,v=e}finally{try{!p&&b.return&&b.return()}finally{if(d)throw v}}e.storage._del(s,r)}else o.includes(t)&&e.storage._del(i,r);o=o.filter(function(e){return e!==t}),e.storage._set(n,o)},b=function(e,t,r){h(e,t);var n=e.namespace+".o",u=e.storage._get(n),a=u||[],i=e.namespace+".p."+t;if(r instanceof s){if(r.__self.storage!==e.storage)throw new Error("Cannot cross Storages");var c={ref:r.__self.namespace};e.storage._set(i,c)}else if("object"===(void 0===r?"undefined":o(r))){var f=l(i,e.storage);for(var p in r)r.hasOwnProperty(p)&&(f[p]=r[p])}else e.storage._set(i,r);a.push(t),e.storage._set(n,a)},m=function(e){var t=e.namespace+".o",r=e.storage._get(t),n=!0,u=!1,o=void 0;try{for(var i,s=a(r);!(n=(i=s.next()).done);n=!0){var c=i.value;h(e,c)}}catch(e){u=!0,o=e}finally{try{!n&&s.return&&s.return()}finally{if(u)throw o}}},g=(f=u(n.mark(function e(t){return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,i(t.namespace,t.storage,function(e,t){h(e,t,!1)});case 2:case"end":return e.stop()}},e,void 0)})),function(e){return f.apply(this,arguments)}),y=function(e,t){var r=e.namespace+".o";return e.storage._get(r).includes(t)},x=function(e){var t=e.namespace+".o";return e.storage._get(t)},_=function(e,t){var r=d(e,t);return r?{value:r,writable:!0,enumerable:!0,configurable:!0}:void 0};t.default=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=i(r(1)).default,u=i(r(0)).default,a=i(r(8)).default,o=i(r(16)).default;function i(e){return e&&e.__esModule?e:{default:e}}var s,c=(s=u(n.mark(function e(t,r){return n.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a(t,r);case 2:return e.abrupt("return",o(t,r));case 3:case"end":return e.stop()}},e,void 0)})),function(e,t){return s.apply(this,arguments)});t.default=c},function(e,t,r){"use strict";var n=r(17).default,u=r(4).default,a=r(14).default;e.exports={ObjectDB:n,Storage:u,LocalStorage:a}}])}); | ||
//# sourceMappingURL=object.database.node.map |
{ | ||
"name": "object.database", | ||
"version": "1.8.0", | ||
"version": "1.8.1", | ||
"description": "object.database", | ||
@@ -28,4 +28,3 @@ "main": "lib/object.database.node.js", | ||
"babel-runtime": "^6.26.0", | ||
"lodash": "^4.17.10", | ||
"node-localstorage": "^1.3.0" | ||
"lodash": "^4.17.10" | ||
}, | ||
@@ -32,0 +31,0 @@ "directories": { |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
82911
2
46
- Removednode-localstorage@^1.3.0
- Removedgraceful-fs@4.2.11(transitive)
- Removedimurmurhash@0.1.4(transitive)
- Removednode-localstorage@1.3.1(transitive)
- Removedslide@1.1.6(transitive)
- Removedwrite-file-atomic@1.3.4(transitive)