Skip to content

Commit 55c9739

Browse files
stanislaw-grinvengrov
authored andcommitted
refactor: remove unused variables and methods
1 parent 5ac317e commit 55c9739

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

libs/backendless.js

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@
2727

2828
var isBrowser = (new Function("try {return this===window;}catch(e){ return false;}"))();
2929

30+
var WebSocket = null; // isBrowser ? window.WebSocket || window.MozWebSocket : {};
31+
var UIState = null;
32+
3033
var previousBackendless = root.Backendless;
3134

3235
var Backendless = {},
@@ -70,14 +73,6 @@
7073
};
7174
}
7275

73-
var ArrayProto = Array.prototype, ObjProto = Object.prototype, FuncProto = Function.prototype;
74-
75-
var slice = ArrayProto.slice, unshift = ArrayProto.unshift, toString = ObjProto.toString, hasOwnProperty = ObjProto.hasOwnProperty;
76-
77-
var nativeForEach = ArrayProto.forEach, nativeMap = ArrayProto.map, nativeReduce = ArrayProto.reduce, nativeReduceRight = ArrayProto.reduceRight, nativeFilter = ArrayProto.filter, nativeEvery = ArrayProto.every, nativeSome = ArrayProto.some, nativeIndexOf = ArrayProto.indexOf, nativeLastIndexOf = ArrayProto.lastIndexOf, nativeIsArray = Array.isArray, nativeKeys = Object.keys, nativeBind = FuncProto.bind;
78-
79-
var WebSocket = null; // isBrowser ? window.WebSocket || window.MozWebSocket : {};
80-
8176
initXHR();
8277

8378
var browser = (function() {
@@ -100,7 +95,6 @@
10095
return browser;
10196
})();
10297

103-
var UIState = null;
10498
var getNow = function() {
10599
return new Date().getTime();
106100
};
@@ -134,7 +128,7 @@
134128
}
135129
};
136130

137-
Utils.isArray = (nativeIsArray || function(obj) {
131+
Utils.isArray = (Array.isArray || function(obj) {
138132
return Object.prototype.toString.call(obj).slice(8, -1) === 'Array';
139133
});
140134

0 commit comments

Comments
 (0)