MCPcopy Create free account
hub / github.com/Tron521/codex-console-temp / resolveCountryAlias

Function resolveCountryAlias

static/js/payment.js:340–355  ·  view source on GitHub ↗
(raw)

Source from the content-addressed store, hash-verified

338}
339
340function resolveCountryAlias(raw) {
341 const key = String(raw || "").trim();
342 if (!key) return null;
343 const normalized = key.toLowerCase();
344 if (COUNTRY_ALIAS_MAP[normalized]) {
345 return COUNTRY_ALIAS_MAP[normalized];
346 }
347 const upper = key.toUpperCase();
348 if (BILLING_COUNTRY_CURRENCY_MAP[upper]) {
349 return {
350 code: upper,
351 currency: BILLING_COUNTRY_CURRENCY_MAP[upper],
352 };
353 }
354 return null;
355}
356
357function normalizeMonth(value) {
358 const digits = String(value || "").replace(/\D/g, "");

Callers 1

parseCardTextFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected