Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
server_events_dispatch: Throw blueslip if wrong op in realm_bot case.
YashRE424ffdfb5f0006
diff --git a/frontend_tests/node_tests/dispatch.js b/frontend_tests/node_tests/dispatch.jsindex aae857645ee..03ad461c8a1 100644--- a/frontend_tests/node_tests/dispatch.js+++ b/frontend_tests/node_tests/dispatch.js@@ -888,4 +888,6 @@ run_test("server_event_dispatch_op_errors", () => {op: "update_dict",property: "other",});+ blueslip.expect("error", "Unexpected event type realm_bot/other");+ server_events_dispatch.dispatch_normal_event({type: "realm_bot", op: "other"});});diff --git a/static/js/server_events_dispatch.js b/static/js/server_events_dispatch.jsindex 31a005365cd..fdbb3587f85 100644--- a/static/js/server_events_dispatch.js+++ b/static/js/server_events_dispatch.js@@ -316,6 +316,9 @@ export function dispatch_normal_event(event) {settings_bots.eventually_render_bots();settings_users.update_bot_data(event.bot.user_id);break;+ default:+ blueslip.error("Unexpected event type realm_bot/" + event.op);+ break;}break;case "realm_emoji":