Skip to content

Commit f312a89

Browse files
gxcsoccerQix-
authored andcommittedOct 10, 2018
fix: performance issue
1 parent 9a6d8c2 commit f312a89

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed
 

‎src/common.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -64,15 +64,15 @@ function setup(env) {
6464
var prevTime;
6565

6666
function debug() {
67-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
68-
args[_key] = arguments[_key];
69-
}
70-
7167
// Disabled?
7268
if (!debug.enabled) {
7369
return;
7470
}
7571

72+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
73+
args[_key] = arguments[_key];
74+
}
75+
7676
var self = debug; // Set `diff` timestamp
7777

7878
var curr = Number(new Date());

0 commit comments

Comments
 (0)
Please sign in to comment.