Function: normalizeSelectionString()
Makaio Framework / services-core / normalizeSelectionString
Function: normalizeSelectionString()
Section titled “Function: normalizeSelectionString()”normalizeSelectionString(
value):string|undefined
Defined in: ../../../packages/services/core/src/session/selection-utils.ts:22
Normalize a selection string field by trimming whitespace and coercing
blank strings to undefined.
Used wherever adapter/agent selection strings are read from wire payloads to ensure callers cannot accidentally pass whitespace-only values as meaningful adapter names or IDs.
Parameters
Section titled “Parameters”string | undefined
Candidate string value from a selection payload field
Returns
Section titled “Returns”string | undefined
Trimmed non-empty string, or undefined when the input is absent
or contains only whitespace