diff options
Diffstat (limited to 'src/event/server_events.c')
-rw-r--r-- | src/event/server_events.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/event/server_events.c b/src/event/server_events.c index 105c7d72..e6738833 100644 --- a/src/event/server_events.c +++ b/src/event/server_events.c @@ -665,6 +665,14 @@ sv_ev_room_occupant_offline(const char *const room, const char *const nick, mucwin_occupant_offline(mucwin, nick); } prefs_free_string(muc_status_pref); + + Jid *jidp = jid_create_from_bare_and_resource(room, nick); + ProfPrivateWin *privwin = wins_get_private(jidp->fulljid); + jid_destroy(jidp); + if (privwin != NULL) { + privwin_occupant_offline(privwin); + } + occupantswin_occupants(room); rosterwin_roster(); } @@ -840,6 +848,14 @@ sv_ev_muc_occupant_online(const char *const room, const char *const nick, const mucwin_occupant_online(mucwin, nick, role, affiliation, show, status); } prefs_free_string(muc_status_pref); + + Jid *jidp = jid_create_from_bare_and_resource(mucwin->roomjid, nick); + ProfPrivateWin *privwin = wins_get_private(jidp->fulljid); + jid_destroy(jidp); + if (privwin) { + privwin_occupant_online(privwin); + } + occupantswin_occupants(room); rosterwin_roster(); return; |