Skip to content

Commit

Permalink
[FIX] wrong context passed in collection.create
Browse files Browse the repository at this point in the history
  • Loading branch information
olhapi committed Jan 23, 2024
1 parent e6d434e commit 8c0916a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backbone.js
Original file line number Diff line number Diff line change
Expand Up @@ -1085,7 +1085,7 @@
var success = options.success;
options.success = function(m, resp, callbackOpts) {
if (wait) {
m.off('error', this._forwardPristineError, this);
m.off('error', collection._forwardPristineError, collection);
collection.add(m, callbackOpts);
}
if (success) success.call(callbackOpts.context, m, resp, callbackOpts);
Expand Down

0 comments on commit 8c0916a

Please sign in to comment.