fix: fix undefined error while deleting community channel
This commit is contained in:
parent
a4ea767ab6
commit
ffac03aa26
|
@ -162,14 +162,14 @@ StatusPopupMenu {
|
||||||
ConfirmationDialog {
|
ConfirmationDialog {
|
||||||
property string chatId: !!chatItem ? chatItem.id : ""
|
property string chatId: !!chatItem ? chatItem.id : ""
|
||||||
btnType: "warn"
|
btnType: "warn"
|
||||||
header.title: communityActive ? qsTr("Delete #%1").arg(chatItem.name) :
|
header.title: communityActive && chatItem ? qsTr("Delete #%1").arg(chatItem.name) :
|
||||||
chatItem && chatItem.chatType === Constants.chatTypeOneToOne ?
|
chatItem && chatItem.chatType === Constants.chatTypeOneToOne ?
|
||||||
//% "Delete chat"
|
//% "Delete chat"
|
||||||
qsTrId("delete-chat") :
|
qsTrId("delete-chat") :
|
||||||
//% "Leave chat"
|
//% "Leave chat"
|
||||||
qsTrId("leave-chat")
|
qsTrId("leave-chat")
|
||||||
confirmButtonLabel: communityActive ? qsTr("Delete") : header.title
|
confirmButtonLabel: communityActive ? qsTr("Delete") : header.title
|
||||||
confirmationText: communityActive ? qsTr("Are you sure you want to delete #%1 channel?").arg(chatItem.name) :
|
confirmationText: communityActive && chatItem ? qsTr("Are you sure you want to delete #%1 channel?").arg(chatItem.name) :
|
||||||
chatItem && chatItem.chatType === Constants.chatTypeOneToOne ?
|
chatItem && chatItem.chatType === Constants.chatTypeOneToOne ?
|
||||||
qsTr("Are you sure you want to delete this chat?"):
|
qsTr("Are you sure you want to delete this chat?"):
|
||||||
qsTr("Are you sure you want to leave this chat?")
|
qsTr("Are you sure you want to leave this chat?")
|
||||||
|
|
Loading…
Reference in New Issue