mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 13:33:24 +00:00
presence: Add user_id to presence event.
In a later commit, we will eliminate email for clients who have set slim_presence as their preference.
This commit is contained in:
@@ -380,13 +380,7 @@ exports.initialize = function () {
|
||||
setInterval(get_full_presence_list_update, ACTIVE_PING_INTERVAL_MS);
|
||||
};
|
||||
|
||||
exports.update_presence_info = function (email, info, server_time) {
|
||||
const user_id = people.get_user_id(email);
|
||||
if (!user_id) {
|
||||
blueslip.warn('unknown email: ' + email);
|
||||
return;
|
||||
}
|
||||
|
||||
exports.update_presence_info = function (user_id, info, server_time) {
|
||||
presence.set_info_for_user(user_id, info, server_time);
|
||||
exports.redraw_user(user_id);
|
||||
exports.update_huddles();
|
||||
|
||||
@@ -56,7 +56,7 @@ exports.dispatch_normal_event = function dispatch_normal_event(event) {
|
||||
break;
|
||||
|
||||
case 'presence':
|
||||
activity.update_presence_info(event.email, event.presence, event.server_timestamp);
|
||||
activity.update_presence_info(event.user_id, event.presence, event.server_timestamp);
|
||||
break;
|
||||
|
||||
case 'restart': {
|
||||
|
||||
Reference in New Issue
Block a user