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

Function candidateCreatedAt

packages/core/sdk/src/oauth-service.ts:705–716  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

703 // epoch ms for deterministic oldest-first ordering; an unparseable/missing
704 // value sorts as 0 (oldest), so slug then breaks the tie stably.
705 const candidateCreatedAt = (value: unknown): number => {
706 if (value instanceof Date) {
707 const ms = value.getTime();
708 return Number.isFinite(ms) ? ms : 0;
709 }
710 if (typeof value === "number") return Number.isFinite(value) ? value : 0;
711 if (typeof value === "string") {
712 const ms = Date.parse(value);
713 return Number.isFinite(ms) ? ms : 0;
714 }
715 return 0;
716 };
717
718 const dcrCandidatesForIssuer = (
719 owner: Owner,

Callers 1

dcrCandidatesForIssuerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected