MCPcopy Create free account
hub / github.com/pollinations/pollinations / parseEmailList

Function parseEmailList

shared/auth/api-key.ts:85–93  ·  view source on GitHub ↗
(raw: string | undefined | null)

Source from the content-addressed store, hash-verified

83}
84
85export function parseEmailList(raw: string | undefined | null): Set<string> {
86 if (!raw) return new Set();
87 const emails = new Set<string>();
88 for (const part of raw.split(",")) {
89 const normalized = normalizeEmail(part);
90 if (normalized) emails.add(normalized);
91 }
92 return emails;
93}
94
95function normalizeEmail(value: string | null | undefined): string | null {
96 const normalized = value?.trim().toLowerCase();

Callers 2

assertStagingAccessFunction · 0.85

Calls 2

normalizeEmailFunction · 0.85
addMethod · 0.80

Tested by

no test coverage detected