Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
server_events_dispatch: Refactor typing event to use switch/case.
YashRE428d578c248f66
diff --git a/static/js/server_events_dispatch.js b/static/js/server_events_dispatch.jsindex f0dbb5840c8..4ed8231aa8a 100644--- a/static/js/server_events_dispatch.js+++ b/static/js/server_events_dispatch.js@@ -479,11 +479,13 @@ export function dispatch_normal_event(event) {// as well as recipients; we ignore such self-generated events.return;}-- if (event.op === "start") {- typing_events.display_notification(event);- } else if (event.op === "stop") {- typing_events.hide_notification(event);+ switch (event.op) {+ case "start":+ typing_events.display_notification(event);+ break;+ case "stop":+ typing_events.hide_notification(event);+ break;}break;