提交 608ca284 编写于 作者: G Gabriele Cirulli

improve code structure in localscoremanager

上级 88278792
window.fakeStorage = {
_data : {},
setItem : function (id, val) {
console.log("set");
_data: {},
setItem: function (id, val) {
return this._data[id] = String(val);
},
getItem : function (id) {
getItem: function (id) {
return this._data.hasOwnProperty(id) ? this._data[id] : undefined;
},
removeItem : function (id) { return delete this._data[id]; },
clear : function () { return this._data = {}; }
removeItem: function (id) {
return delete this._data[id];
},
clear: function () {
return this._data = {};
}
};
function LocalScoreManager() {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册