Better client side errors when there are issues communicating with trakt.

This commit is contained in:
Mark McDowall 2013-09-08 23:40:24 -07:00
parent 377e5d28e9
commit 0c57c6a6c1
10 changed files with 95 additions and 37 deletions

View file

@ -73,8 +73,14 @@
return false;
}
else if (xmlHttpRequest.status === 503) {
message.message = xmlHttpRequest.responseJSON.message;
}
message.message = '[{0}] {1} : {2}'.format(ajaxOptions.type, xmlHttpRequest.statusText, ajaxOptions.url);
else
{
message.message = '[{0}] {1} : {2}'.format(ajaxOptions.type, xmlHttpRequest.statusText, ajaxOptions.url);
}
window.Messenger().post(message);
return false;