(owner: Owner)
| 1540 | }; |
| 1541 | |
| 1542 | const ownedKeys = (owner: Owner): OwnedKeys => { |
| 1543 | if (owner === "org") return { tenant, owner, subject: ORG_SUBJECT }; |
| 1544 | if (subject == null) { |
| 1545 | // oxlint-disable-next-line executor/no-try-catch-or-throw -- boundary: programmer error caught and surfaced as StorageError below by callers |
| 1546 | throw new StorageError({ |
| 1547 | message: `Cannot target owner "user": executor has no subject.`, |
| 1548 | cause: undefined, |
| 1549 | }); |
| 1550 | } |
| 1551 | return { tenant, owner, subject }; |
| 1552 | }; |
| 1553 | |
| 1554 | const requireUserSubject = (owner: Owner): Effect.Effect<void, StorageFailure> => |
| 1555 | owner === "user" && subject == null |
no outgoing calls
no test coverage detected