Files
test-openclaw/src/gateway/server-methods/record-shared.ts
T

10 lines
302 B
TypeScript

export { asOptionalRecord as asRecord } from "../../shared/record-coerce.js";
export function normalizeTrimmedString(value: unknown): string | undefined {
if (typeof value !== "string") {
return undefined;
}
const trimmed = value.trim();
return trimmed.length > 0 ? trimmed : undefined;
}