MCPcopy Create free account
hub / github.com/CommE2E/comm / sanitizeInput

Function sanitizeInput

keyserver/src/utils/validation-utils.js:139–147  ·  view source on GitHub ↗
(inputValidator: TType<T>, input: T)

Source from the content-addressed store, hash-verified

137const redactedString = '********';
138const redactedTypes = [tPassword, tCookie];
139function sanitizeInput<T>(inputValidator: TType<T>, input: T): T {
140 return convertObject(
141 inputValidator,
142 input,
143 redactedTypes,
144 () => redactedString,
145 { dontValidateInput: true },
146 );
147}
148
149function findFirstInputMatchingValidator(
150 wholeInputValidator: any,

Callers 2

checkInputValidatorFunction · 0.85

Calls 1

convertObjectFunction · 0.90

Tested by

no test coverage detected