mirror of
https://github.com/wbbaddons/Tims-Chat.git
synced 2024-12-22 21:40:08 +00:00
Fixing errorhandling of getMessages
Set loading to false in complete, instead of success
This commit is contained in:
parent
b141fac033
commit
864f00f284
@ -278,7 +278,6 @@ window.console ?=
|
||||
dataType: 'json'
|
||||
type: 'POST'
|
||||
success: $.proxy((data, textStatus, jqXHR) ->
|
||||
@loading = false
|
||||
@handleMessages(data.messages)
|
||||
@handleUsers(data.users)
|
||||
, @)
|
||||
@ -290,6 +289,9 @@ window.console ?=
|
||||
@freeTheFish()
|
||||
console.error 'We got destroyed, but could free our friend the fish before he was killed as well. Have a nice life in freedom!'
|
||||
alert 'herp i cannot load messages'
|
||||
, @),
|
||||
complete: $.proxy(() ->
|
||||
@loading = false
|
||||
, @)
|
||||
beforeSend: $.proxy(() ->
|
||||
return false if @loading
|
||||
|
Loading…
Reference in New Issue
Block a user