Skip to main content

stripPrivateFields

@webda/core


Function: stripPrivateFields()

stripPrivateFields<T>(input): T

Defined in: packages/core/src/services/domainservice.service.ts:137

Remove __-prefixed keys at any depth from client-supplied input, so private fields (such as a password hash) can never be set through the REST/operations surface

Type Parameters​

T​

T = any

Parameters​

input​

T

the client input

Returns​

T

a sanitized deep copy (non plain-object/array values are returned as is)