Fix typing.

This commit is contained in:
Sam Rose 2024-03-05 14:40:29 +00:00
parent fced2f3696
commit 488cfea1f4
No known key found for this signature in database
1 changed files with 1 additions and 1 deletions

View File

@ -184,7 +184,7 @@ export async function getRole(
return cloneDeep(BUILTIN_ROLES.PUBLIC)
}
// only throw an error if there is no role at all
if (Object.keys(role || {}).length === 0) {
if (!role || Object.keys(role).length === 0) {
throw err
}
}