From ebe0cc6f4586ebf3dd011aac7c2b21f25b079675 Mon Sep 17 00:00:00 2001 From: Ryan W Tenney Date: Fri, 3 Dec 2010 14:34:25 -0500 Subject: [PATCH] Access the `_wrapped` property directly instead of calling `value()` when unwrapping wrapped objects in `isEqual()` --- underscore.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/underscore.js b/underscore.js index 87c5e4ec8..7b5d2d6c6 100644 --- a/underscore.js +++ b/underscore.js @@ -529,8 +529,8 @@ // One is falsy and the other truthy. if ((!a && b) || (a && !b)) return false; // Unwrap any wrapped objects. - if (a._chain) a = a.value(); - if (b._chain) b = b.value(); + if (a._chain) a = a._wrapped; + if (b._chain) b = b._wrapped; // One of them implements an isEqual()? if (a.isEqual) return a.isEqual(b); // Check dates' integer values.