From 38d6b694fb01418335163d4ce58ab4ab091cc2e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Tinkl?= Date: Fri, 19 Apr 2024 00:10:45 +0200 Subject: [PATCH] fix(ProfileContextMenu): do not display extra Send CR when pending - do not display the "Send contact request" menu item when we've already sent one; happened because now we have an enum for the contact request state --- ui/imports/shared/views/chat/ProfileContextMenu.qml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ui/imports/shared/views/chat/ProfileContextMenu.qml b/ui/imports/shared/views/chat/ProfileContextMenu.qml index 55182f8ead..417b49338e 100644 --- a/ui/imports/shared/views/chat/ProfileContextMenu.qml +++ b/ui/imports/shared/views/chat/ProfileContextMenu.qml @@ -148,8 +148,9 @@ StatusMenu { SendContactRequestMenuItem { id: sendContactRequestMenuItem objectName: "sendContactRequest_StatusItem" - enabled: !root.isMe && !root.isContact - && !root.isBlockedContact && !root.hasPendingContactRequest && !root.isBridgedAccount + enabled: !root.isMe && !root.isContact && !root.isBlockedContact + && (contactDetails.contactRequestState === Constants.ContactRequestState.None || contactDetails.contactRequestState === Constants.ContactRequestState.Dismissed) + && !root.isBridgedAccount onTriggered: Global.openContactRequestPopup(root.selectedUserPublicKey, root.contactDetails, null) }