Use QML safe member for invitations
Has the sideeffect of making sure that the avatar colors are the same between the invitation view and the sidebar
This commit is contained in:
committed by
Tobias Fella
parent
29abe0bacb
commit
207c824ec7
@@ -16,7 +16,7 @@ ColumnLayout {
|
||||
id: root
|
||||
|
||||
required property NeoChatRoom currentRoom
|
||||
readonly property var invitingMember: currentRoom.member(currentRoom.invitingUserId)
|
||||
readonly property var invitingMember: currentRoom.qmlSafeMember(currentRoom.invitingUserId)
|
||||
readonly property string inviteTimestamp: root.currentRoom.inviteTimestamp.toLocaleString(Qt.locale(), Locale.ShortFormat)
|
||||
|
||||
spacing: Kirigami.Units.smallSpacing
|
||||
|
||||
@@ -557,7 +557,7 @@ public:
|
||||
* responsibility of the caller to ensure that they only ask for objects
|
||||
* for real senders.
|
||||
*/
|
||||
NeochatRoomMember *qmlSafeMember(const QString &memberId);
|
||||
Q_INVOKABLE NeochatRoomMember *qmlSafeMember(const QString &memberId);
|
||||
|
||||
/**
|
||||
* @brief Pin a message in the room.
|
||||
|
||||
Reference in New Issue
Block a user