export function coerceToNull(input: T | null | undefined): T | null { return input ?? null; } export function coerceToUndefined( input: T | null | undefined, ): T | undefined { return input ?? undefined; }