Fix all references

This commit is contained in:
Adria Navarro 2024-10-17 11:53:20 +02:00
parent 1155be4530
commit 8008d2ced1
1 changed files with 2 additions and 2 deletions

View File

@ -384,8 +384,8 @@ export async function getAllRoles(appId?: string): Promise<RoleDoc[]> {
} }
async function shouldIncludePowerRole(db: Database) { async function shouldIncludePowerRole(db: Database) {
const app = await db.get<App>(DocumentType.APP_METADATA) const app = await db.tryGet<App>(DocumentType.APP_METADATA)
const { creationVersion } = app const creationVersion = app?.creationVersion
if (!creationVersion) { if (!creationVersion) {
// Old apps don't have creationVersion, so we should include it for backward compatibility // Old apps don't have creationVersion, so we should include it for backward compatibility
return true return true