diff --git a/src/script/page/RightSidebar/ConversationDetails/utils/getConversationActions.ts b/src/script/page/RightSidebar/ConversationDetails/utils/getConversationActions.ts index 641ac873d0c..8814e0b0598 100644 --- a/src/script/page/RightSidebar/ConversationDetails/utils/getConversationActions.ts +++ b/src/script/page/RightSidebar/ConversationDetails/utils/getConversationActions.ts @@ -151,11 +151,7 @@ const getConversationActions = ({ }, }, { - condition: - !isSingleUser && - isTeam && - roleRepository.canDeleteGroup(conversationEntity) && - conversationEntity.isCreatedBySelf(), + condition: !isSingleUser && isTeam && roleRepository.canDeleteGroup(conversationEntity), item: { click: async () => actionsViewModel.deleteConversation(conversationEntity), Icon: Icon.DeleteIcon, diff --git a/src/script/view_model/ActionsViewModel.ts b/src/script/view_model/ActionsViewModel.ts index f5a9205cd8f..e6cb755e90f 100644 --- a/src/script/view_model/ActionsViewModel.ts +++ b/src/script/view_model/ActionsViewModel.ts @@ -303,22 +303,18 @@ export class ActionsViewModel { }; readonly deleteConversation = (conversationEntity: Conversation): Promise => { - if (conversationEntity && conversationEntity.isCreatedBySelf()) { - return new Promise(() => { - PrimaryModal.show(PrimaryModal.type.CONFIRM, { - primaryAction: { - action: () => this.conversationRepository.deleteConversation(conversationEntity), - text: t('modalConversationDeleteGroupAction'), - }, - text: { - message: t('modalConversationDeleteGroupMessage'), - title: t('modalConversationDeleteGroupHeadline', conversationEntity.display_name()), - }, - }); + return new Promise(() => { + PrimaryModal.show(PrimaryModal.type.CONFIRM, { + primaryAction: { + action: () => this.conversationRepository.deleteConversation(conversationEntity), + text: t('modalConversationDeleteGroupAction'), + }, + text: { + message: t('modalConversationDeleteGroupMessage'), + title: t('modalConversationDeleteGroupHeadline', conversationEntity.display_name()), + }, }); - } - - return Promise.reject(); + }); }; getConversationById = async (conversation: QualifiedId): Promise => {