chore: only run leave function if dialog result is yes (#2011)
This commit is contained in:
parent
04315eaf10
commit
2b17945194
2 changed files with 5 additions and 2 deletions
|
|
@ -933,7 +933,10 @@ class ChatListController extends State<ChatList>
|
|||
cancelLabel: L10n.of(context).cancel,
|
||||
isDestructive: true,
|
||||
);
|
||||
if (confirmed == OkCancelResult.cancel) return;
|
||||
// #Pangea
|
||||
// if (confirmed == OkCancelResult.cancel) return;
|
||||
if (confirmed != OkCancelResult.ok) return;
|
||||
// Pangea#
|
||||
if (!mounted) return;
|
||||
|
||||
// #Pangea
|
||||
|
|
|
|||
|
|
@ -420,7 +420,7 @@ class PangeaChatDetailsView extends StatelessWidget {
|
|||
: L10n.of(context).leaveRoomDescription,
|
||||
isDestructive: true,
|
||||
);
|
||||
if (confirmed == OkCancelResult.cancel) return;
|
||||
if (confirmed != OkCancelResult.ok) return;
|
||||
final resp = await showFutureLoadingDialog(
|
||||
context: context,
|
||||
future:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue