Skip to content

Commit

Permalink
reactions: Downgrade blueslip error to a warning.
Browse files Browse the repository at this point in the history
When we get a server error for adding/removing a reaction, we
no longer make a blueslip error, since it is somewhat common for
users to retry actions before the server sends an event.  The
code comment that is part of this commit explains this further.

Fixes zulip#4290.
  • Loading branch information
showell authored and timabbott committed Mar 25, 2017
1 parent d4b56df commit b3e4aa4
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion static/js/reactions.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,12 @@ function send_reaction_ajax(message_id, emoji_name, operation) {
success: function () {},
error: function (xhr) {
var response = channel.xhr_error_message("Error sending reaction", xhr);
blueslip.error(response);
// Errors are somewhat commmon here, due to race conditions
// where the user tries to add/remove the reaction when there is already
// an in-flight request. We eventually want to make this a blueslip
// error, rather than a warning, but we need to implement either
// #4291 or #4295 first.
blueslip.warn(response);
},
};
if (operation === 'add') {
Expand Down

0 comments on commit b3e4aa4

Please sign in to comment.