js: Add braces to case blocks declaring variables.

This helps to prepare for the migration of `var` to `let` and `const`.

Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
This commit is contained in:
Anders Kaseorg
2019-10-25 14:55:37 -07:00
committed by Tim Abbott
parent 12bd3c04c0
commit a547413347
8 changed files with 36 additions and 19 deletions

View File

@@ -499,13 +499,14 @@ exports.validation_error = function (error_type, stream_name) {
compose_error(i18n.t("Error checking subscription"),
$("#stream_message_recipient_stream"));
return false;
case "not-subscribed":
case "not-subscribed": {
var sub = stream_data.get_sub(stream_name);
var new_row = render_compose_not_subscribed({
should_display_sub_button: sub.should_display_subscription_button});
compose_not_subscribed_error(new_row, $('#stream_message_recipient_stream'));
return false;
}
}
return true;
};