fix: Handle null case (#2118)
This commit is contained in:
parent
d21594a6f4
commit
6ef8d9ddb3
@ -229,6 +229,10 @@ Collection.membershipUserIds = async (collectionId: string) => {
|
||||
collectionId
|
||||
);
|
||||
|
||||
if (!collection) {
|
||||
return [];
|
||||
}
|
||||
|
||||
const groupMemberships = collection.collectionGroupMemberships
|
||||
.map((cgm) => cgm.group.groupMemberships)
|
||||
.flat();
|
||||
|
Reference in New Issue
Block a user