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

Function nonEmpty

apps/api/src/config/env/validate.ts:101–107  ·  view source on GitHub ↗
(raw: string | undefined, fallback: string)

Source from the content-addressed store, hash-verified

99};
100
101export const nonEmpty = (raw: string | undefined, fallback: string): string => {
102 if (raw === undefined || raw === "") {
103 return fallback;
104 }
105
106 return raw;
107};
108
109export const toCsv = (raw: string | undefined): string[] => {
110 if (raw === undefined || raw === "") {

Callers 4

validate.test.tsFile · 0.90
readDatabaseFunction · 0.85
readAuthFunction · 0.85
readUrlsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected