if userID is null, don't try to get isRoomAdmin

This commit is contained in:
ggurdin 2024-10-25 11:05:59 -04:00
parent cd5f2379b8
commit 212632a913
No known key found for this signature in database
GPG key ID: A01CB41737CBB478

View file

@ -10,7 +10,7 @@ extension AnalyticsRoomExtension on Room {
return;
}
if (!isRoomAdmin) return;
if (client.userID == null || !isRoomAdmin) return;
final spaceHierarchy = await client.getSpaceHierarchy(
id,
maxDepth: 1,