8000 Use instanceof instead of __proto__. · f2er/jquery.transit@f56e204 · GitHub
[go: up one dir, main page]

Skip to content

Commit f56e204

Browse files
committed
Use instanceof instead of __proto__.
1 parent fd6aa5c commit f56e204

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

jquery.transit.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
// The setter accepts a `Transform` object or a string.
5555
set: function(elem, value) {
5656
var transform = value;
57-
if (transform.__proto__ != Transform.prototype)
57+
if (!(transform instanceof Transform))
5858
transform = new Transform(transform);
5959

6060
setVendorProperty(elem, 'Transform',
@@ -130,7 +130,7 @@
130130
var args = (typeof val === 'string') ? val.split(',') : [val];
131131
args.unshift(prop);
132132

133-
this.__proto__.set.apply(this, args);
133+
Transform.prototype.set.apply(this, args);
134134
},
135135

136136
// ### set()

0 commit comments

Comments
 (0)
0