* Resolve platform-admin status lazily. Dynamically imported so the DB-backed * helper (and `@sim/db`) stay out of this config module's load graph for callers * that never reach an admin-gated flag.
(userId: string)
| 170 | * that never reach an admin-gated flag. |
| 171 | */ |
| 172 | async function resolveAdmin(userId: string): Promise<boolean> { |
| 173 | const { isPlatformAdmin } = await import('@/lib/permissions/super-user') |
| 174 | return isPlatformAdmin(userId) |
| 175 | } |
| 176 | |
| 177 | /** |
| 178 | * The admin clause is resolved last and lazily: a global/userId/orgId match |
no test coverage detected