mirror of
https://github.com/hcengineering/platform.git
synced 2026-09-22 01:25:00 +02:00
ezqms-724: make roles related code more robust (#5363)
Signed-off-by: Alexey Zinoviev <alexey.zinoviev@xored.com>
This commit is contained in:
@@ -95,7 +95,7 @@
|
||||
const asMixin = hierarchy.as(teamspace, spaceType?.targetClass)
|
||||
|
||||
return spaceType.$lookup.roles.reduce<RolesAssignment>((prev, { _id }) => {
|
||||
prev[_id as Ref<Role>] = (asMixin as any)[_id]
|
||||
prev[_id as Ref<Role>] = (asMixin as any)[_id] ?? []
|
||||
|
||||
return prev
|
||||
}, {})
|
||||
|
||||
Reference in New Issue
Block a user