Skip to content

Commit

Permalink
toString is a reserved word in older browsers.
Browse files Browse the repository at this point in the history
  • Loading branch information
ljharb committed Jan 20, 2015
1 parent aeb3ff8 commit c9577e4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use strict';

var ObjectPrototype = Object.prototype;
var toString = ObjectPrototype.toString;
var toStr = ObjectPrototype.toString;
var has = ObjectPrototype.hasOwnProperty;
var isGenerator = require('is-generator-function');
var isArrowFunction = require('is-arrow-function');
Expand Down Expand Up @@ -41,8 +41,8 @@ var objType = '[object Object]';
module.exports = function isEqual(value, other) {
if (value === other) { return true; }

var type = toString.call(value);
if (type !== toString.call(other)) { return false; }
var type = toStr.call(value);
if (type !== toStr.call(other)) { return false; }

if (type === boolType) { return value.valueOf() === other.valueOf(); }

Expand Down

0 comments on commit c9577e4

Please sign in to comment.