From 9be5c32d812a55ca55e1cf80d8e29fe593c85a62 Mon Sep 17 00:00:00 2001 From: Kitsune Ral Date: Fri, 27 Apr 2018 13:26:28 +0900 Subject: User::processEvent: fix bridge postfix not being stripped Closes #197. --- lib/user.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/user.cpp b/lib/user.cpp index 6143a061..f469128c 100644 --- a/lib/user.cpp +++ b/lib/user.cpp @@ -389,12 +389,12 @@ void User::processEvent(RoomMemberEvent* event, const Room* room) // FIXME: the hint doesn't work for bridged users auto oldNameHint = d->nameForRoom(room, event->prevContent()->displayName); - updateName(event->displayName(), oldNameHint, room); + updateName(newName, oldNameHint, room); updateAvatarUrl(event->avatarUrl(), d->avatarUrlForRoom(room, event->prevContent()->avatarUrl), room); } else { - updateName(event->displayName(), room); + updateName(newName, room); updateAvatarUrl(event->avatarUrl(), d->avatarUrlForRoom(room), room); } } -- cgit v1.2.3