diff options
| author | supahgreg <supahgreg@users.noreply.github.com> | 2025-10-05 04:33:59 +0000 |
|---|---|---|
| committer | supahgreg <supahgreg@users.noreply.github.com> | 2025-10-05 04:34:29 +0000 |
| commit | 46ebef7ebf0ed658333f52cd01e07b07f47b58d9 (patch) | |
| tree | b9fb5d2926aa4d26242ae9ae4e7eb0a335970ff9 /lib/dojo/store/Memory.js | |
| parent | 6e8a188e4a1af8147f358312e182287a0d7bd1c0 (diff) | |
Bump Dojo from 1.16.5 to 1.17.3.
This should help with some of the security findings.
Diffstat (limited to 'lib/dojo/store/Memory.js')
| -rw-r--r-- | lib/dojo/store/Memory.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/dojo/store/Memory.js b/lib/dojo/store/Memory.js index 2d882902c..f27a19c6d 100644 --- a/lib/dojo/store/Memory.js +++ b/lib/dojo/store/Memory.js @@ -5,4 +5,4 @@ */ //>>built -define("dojo/store/Memory",["../_base/declare","./util/QueryResults","./util/SimpleQueryEngine"],function(_1,_2,_3){var _4=null;return _1("dojo.store.Memory",_4,{constructor:function(_5){for(var i in _5){this[i]=_5[i];}this.setData(this.data||[]);},data:null,idProperty:"id",index:null,queryEngine:_3,get:function(id){return this.data[this.index[id]];},getIdentity:function(_6){return _6[this.idProperty];},put:function(_7,_8){var _9=this.data,_a=this.index,_b=this.idProperty;var id=_7[_b]=(_8&&"id" in _8)?_8.id:_b in _7?_7[_b]:Math.random();if(id in _a){if(_8&&_8.overwrite===false){throw new Error("Object already exists");}_9[_a[id]]=_7;}else{_a[id]=_9.push(_7)-1;}return id;},add:function(_c,_d){(_d=_d||{}).overwrite=false;return this.put(_c,_d);},remove:function(id){var _e=this.index;var _f=this.data;if(id in _e){_f.splice(_e[id],1);this.setData(_f);return true;}},query:function(_10,_11){return _2(this.queryEngine(_10,_11)(this.data));},setData:function(_12){if(_12.items){this.idProperty=_12.identifier||this.idProperty;_12=this.data=_12.items;}else{this.data=_12;}this.index={};for(var i=0,l=_12.length;i<l;i++){this.index[_12[i][this.idProperty]]=i;}}});});
\ No newline at end of file +define("dojo/store/Memory",["../_base/declare","./util/QueryResults","./util/SimpleQueryEngine"],function(_1,_2,_3){var _4=null;return _1("dojo.store.Memory",_4,{constructor:function(_5){for(var i in _5){this[i]=_5[i];}this.setData(this.data||[]);},data:null,idProperty:"id",index:null,queryEngine:_3,get:function(id){return this.data[this.index[id]];},getIdentity:function(_6){return _6[this.idProperty];},put:function(_7,_8){var _9=this.data;var _a=this.index;var _b=this.idProperty;var id=_7[_b]=(_8&&"id" in _8)?_8.id:_b in _7?_7[_b]:Math.random();var _c=_9.length;var _d;var _e;var _f=id in _a?"update":"add";if(_f==="update"){if(_8&&_8.overwrite===false){throw new Error("Object already exists");}else{_e=_a[id];_c=_e;}}if(_8&&"before" in _8){if(_8.before==null){_d=_9.length;if(_f==="update"){--_d;}}else{_d=_a[this.getIdentity(_8.before)];if(_e<_d){--_d;}}}else{_d=_c;}if(_d===_e){_9[_d]=_7;}else{if(_e!==undefined){_9.splice(_e,1);}_9.splice(_d,0,_7);this._rebuildIndex(_e===undefined?_d:Math.min(_e,_d));}return id;},add:function(_10,_11){(_11=_11||{}).overwrite=false;return this.put(_10,_11);},remove:function(id){var _12=this.index;var _13=this.data;if(id in _12){_13.splice(_12[id],1);this.index={};this._rebuildIndex();return true;}},query:function(_14,_15){return _2(this.queryEngine(_14,_15)(this.data));},setData:function(_16){if(_16.items){this.idProperty=_16.identifier||this.idProperty;_16=this.data=_16.items;}else{this.data=_16;}this.index={};this._rebuildIndex();},_rebuildIndex:function(_17){var _18=this.data;var _19=_18.length;var i;_17=_17||0;for(i=_17;i<_19;i++){this.index[_18[i][this.idProperty]]=i;}}});});
\ No newline at end of file |