mirror of
https://github.com/zulip/zulip.git
synced 2025-11-17 04:12:02 +00:00
message_list: Fix handling of unknown email in mentions.
If a user has an old mention and has since been renamed, there's really nothing for us to do to render it; we should just return as though we have no data.
This commit is contained in:
@@ -32,7 +32,11 @@ function get_user_id_for_mention_button(elem) {
|
||||
|
||||
if (email) {
|
||||
// Will return undefined if there's no match
|
||||
return people.get_by_email(email).user_id;
|
||||
var user = people.get_by_email(email);
|
||||
if (user) {
|
||||
return user.user_id;
|
||||
}
|
||||
return;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user