This can be simplified to:

```coffeescript
relayErrorCallback = (response) ->
  online = response.status? not in result(Backbone.DualStorage, 'offlineStatusCodes')
  if online
    error resp
  else
    options.dirty = true
    success localsync(method, model, options)
```