Skip to content

Commit 26b61ec

Browse files
committed
- fix type of aruments to arguments
1 parent 093b0a1 commit 26b61ec

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/script.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@
106106
}
107107

108108
function bind(fn) {
109-
var a = [].slice.call(aruments, 1)
109+
var a = Array.prototype.slice.call(arguments, 1)
110110
return function () {
111111
fn.apply(null, a)
112112
}
@@ -118,7 +118,7 @@
118118
el.type = 'text/javascript'
119119
if (preloadExplicit) {
120120
el.preload = true
121-
el.onpreload = bind(fn,el)
121+
el.onpreload = bind(fn, el)
122122
} else {
123123
el[onreadystatechange] = function () {
124124
if (complete.test(el[readyState])) {
@@ -127,7 +127,7 @@
127127
}
128128
}
129129
}
130-
el.src = path
130+
el.src = path // setting .src begins the preload
131131
} else if (async) {
132132
create(path, fn)
133133
} else {

0 commit comments

Comments
 (0)