mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2024-11-23 23:58:02 -05:00
Adding more error handling for George's inventory saving problems.
This commit is contained in:
parent
a700b7844f
commit
c3573b2fbd
1 changed files with 4 additions and 1 deletions
|
@ -126,7 +126,10 @@ class CocoModel extends Backbone.Model
|
|||
return unless @notyErrors
|
||||
errorMessage = "Error saving #{@get('name') ? @type()}"
|
||||
console.error errorMessage, res.responseJSON
|
||||
noty text: "#{errorMessage}: #{res.status} #{res.statusText}", layout: 'topCenter', type: 'error', killer: false, timeout: 10000
|
||||
try
|
||||
noty text: "#{errorMessage}: #{res.status} #{res.statusText}", layout: 'topCenter', type: 'error', killer: false, timeout: 10000
|
||||
catch notyError
|
||||
console.error "Couldn't even show noty error for", error, "because", notyError
|
||||
@trigger 'save', @
|
||||
return super attrs, options
|
||||
|
||||
|
|
Loading…
Reference in a new issue