Make chat list delete similar to leave (close chat on leave) (#3672)
This commit is contained in:
parent
194c25be25
commit
60c1a40e94
1 changed files with 5 additions and 1 deletions
|
|
@ -46,6 +46,7 @@ import '../../widgets/matrix.dart';
|
|||
import 'package:fluffychat/utils/tor_stub.dart'
|
||||
if (dart.library.html) 'package:tor_detector_web/tor_detector_web.dart';
|
||||
|
||||
|
||||
enum PopupMenuAction {
|
||||
settings,
|
||||
invite,
|
||||
|
|
@ -1113,10 +1114,13 @@ class ChatListController extends State<ChatList>
|
|||
if (confirmed != OkCancelResult.ok) return;
|
||||
if (!mounted) return;
|
||||
|
||||
await showFutureLoadingDialog(
|
||||
final resp = await showFutureLoadingDialog(
|
||||
context: context,
|
||||
future: room.delete,
|
||||
);
|
||||
if (mounted && !resp.isError) {
|
||||
context.go("/rooms");
|
||||
}
|
||||
}
|
||||
return;
|
||||
// Pangea#
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue