diff --git a/frontend_tests/node_tests/people.js b/frontend_tests/node_tests/people.js index f0374768c6..de8b3dc91d 100644 --- a/frontend_tests/node_tests/people.js +++ b/frontend_tests/node_tests/people.js @@ -11,7 +11,7 @@ set_global('page_params', { email: 'hamlet@example.com', }); set_global('activity', { - set_user_statuses: function () {}, + redraw: function () {}, }); set_global('admin', { show_or_hide_menu_item: function () {}, diff --git a/static/js/activity.js b/static/js/activity.js index 89ccb2cc19..59d8b7e2c8 100644 --- a/static/js/activity.js +++ b/static/js/activity.js @@ -496,6 +496,11 @@ exports.set_user_statuses = function (users, server_time) { exports.update_huddles(); }; +exports.redraw = function () { + exports.update_users(); + exports.update_huddles(); +}; + exports.searching = function () { return $('.user-list-filter').expectOne().is(':focus'); }; diff --git a/static/js/people.js b/static/js/people.js index 901c5f10b8..7cd37e621d 100644 --- a/static/js/people.js +++ b/static/js/people.js @@ -288,6 +288,10 @@ exports.update = function update(person) { if (util.is_current_user(person.email)) { page_params.fullname = person.full_name; } + + activity.redraw(); + // TODO: update sender names on messages + } if (_.has(person, 'is_admin')) { @@ -312,10 +316,6 @@ exports.update = function update(person) { "background-image": "url(" + url + ")" }); } - - activity.set_user_statuses([]); - - // TODO: update sender names on messages }; $(function () {