Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Gracefully handle errors when retrieving tweets
In case the Twitter API call fails, get-tweets.php now returns the status code in addition to the error details (JSON) in the response body. This allows the client to react properly to the error, as before it would always get an HTTP 200 success status code and did not know that something went wrong. Adding a .fail() handler to the ajax call, displaying an error message; the browser console should log the details about the failed XHR.
- Loading branch information