From 8c4b2ade88897f594b1f0718890bd1d7c65e73bf Mon Sep 17 00:00:00 2001 From: Krille Date: Sat, 20 May 2023 08:21:33 +0200 Subject: [PATCH] fix: Do not unnecessary request all members in public rooms --- lib/pages/chat/encryption_button.dart | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/pages/chat/encryption_button.dart b/lib/pages/chat/encryption_button.dart index d05091f0..371237e0 100644 --- a/lib/pages/chat/encryption_button.dart +++ b/lib/pages/chat/encryption_button.dart @@ -20,7 +20,9 @@ class EncryptionButton extends StatelessWidget { .where((s) => s.deviceLists != null), builder: (context, snapshot) { return FutureBuilder( - future: room.calcEncryptionHealthState(), + future: room.encrypted + ? room.calcEncryptionHealthState() + : Future.value(EncryptionHealthState.allVerified), builder: (BuildContext context, snapshot) => IconButton( tooltip: room.encrypted ? L10n.of(context)!.encrypted