MCPcopy Create free account
hub / github.com/boringstack-xyz/boringstack / isAuth

Function isAuth

apps/api/tests/api/auth/mfa.routes.test.ts:51–57  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

49 value.data.mfaRequired === true;
50
51const isAuth = (value: unknown): value is IAuthBody =>
52 value !== null &&
53 typeof value === "object" &&
54 "data" in value &&
55 value.data !== null &&
56 typeof value.data === "object" &&
57 "user" in value.data;
58
59const totpFor = (secretBase32: string, offsetSteps = 0): string =>
60 new TOTP({

Callers 1

mfa.routes.test.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected