(model, options)
| 2139 | |
| 2140 | // Wrap an optional error callback with a fallback error event. |
| 2141 | var wrapError = function(model, options) { |
| 2142 | var error = options.error; |
| 2143 | options.error = function(resp) { |
| 2144 | if (error) error.call(options.context, model, resp, options); |
| 2145 | model.trigger('error', model, resp, options); |
| 2146 | }; |
| 2147 | }; |
| 2148 | |
| 2149 | // Provide useful information when things go wrong. This method is not meant |
| 2150 | // to be used directly; it merely provides the necessary introspection for the |
no outgoing calls
no test coverage detected
searching dependent graphs…