check if channel.membercount is null

This commit is contained in:
Salvatore Giordano
2020-10-15 11:43:07 +02:00
parent 069f1a8ee4
commit 24d9b244f2
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -16,7 +16,7 @@ class ChannelInfo extends StatelessWidget {
@override
Widget build(BuildContext context) {
if (channel.memberCount > 2) {
if (channel.memberCount != null && channel.memberCount > 2) {
return Text(
'${channel.memberCount} Members, ${channel.state.watcherCount} Online',
style: StreamChatTheme.of(context)