Skip to content

Commit

Permalink
fixing broken comparison.
Browse files Browse the repository at this point in the history
  • Loading branch information
jashkenas committed Oct 31, 2011
1 parent 35600be commit 18be710
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions backbone.js
Original file line number Diff line number Diff line change
Expand Up @@ -1149,9 +1149,9 @@
};

// Wrap an optional error callback with a fallback error event.
var wrapError = function(onError, model, options) {
var wrapError = function(onError, originalModel, options) {
return function(model, resp) {
var resp = model === model ? resp : model;
var resp = model === originalModel ? resp : model;
if (onError) {
onError(model, resp, options);
} else {
Expand Down

0 comments on commit 18be710

Please sign in to comment.