Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

narrow: Add minor comment.

Aman Agrawal7d41c8ce062b
diff --git a/web/src/narrow.js b/web/src/narrow.js
index a278fc88b6a..c9567b1175f 100644
--- a/web/src/narrow.js
+++ b/web/src/narrow.js
@@ -475,7 +475,11 @@ export function activate(raw_terms, opts) {
// This needs to be called at the same time as updating the
// current message list so that we don't need to think about
// bugs related to the URL fragment/hash being desynced from
- // mesasge_lists.current.
+ // message_lists.current.
+ //
+ // It's fine for the hash change to happen anytime before updating
+ // the current message list as we are trying to emulate the `hashchange`
+ // workflow we have which calls `narrow.activate` after hash is updated.
if (opts.change_hash) {
update_hash_to_match_filter(filter, opts.trigger);
}