MCPcopy Create free account
hub / github.com/Gan-Xing/CodexBridge / normalizeStringArray

Function normalizeStringArray

src/core/bridge_coordinator.ts:17155–17159  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

17153}
17154
17155function normalizeStringArray(value: unknown): string[] {
17156 return Array.isArray(value)
17157 ? value.map((entry) => compactWhitespace(entry)).filter(Boolean).slice(0, 12)
17158 : [];
17159}
17160
17161function truncateText(value, limit) {
17162 const normalized = String(value ?? '').trim();

Calls 1

compactWhitespaceFunction · 0.70

Tested by

no test coverage detected