MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / asString

Function asString

apps/cli/src/device-login.ts:65–66  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

63const cliLoginUrl = (origin: string): string => `${origin.replace(/\/+$/, "")}/api/auth/cli-login`;
64
65const asString = (value: unknown): string | undefined =>
66 typeof value === "string" && value.length > 0 ? value : undefined;
67
68const asNumber = (value: unknown): number | undefined =>
69 typeof value === "number" && Number.isFinite(value) ? value : undefined;

Callers 5

readUserEmailFunction · 0.85
discoverCliLoginFunction · 0.85
requestDeviceCodeFunction · 0.85
pollForDeviceTokensFunction · 0.85
refreshDeviceTokensFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected