MCPcopy
hub / github.com/infinitered/reactotron / parseRules

Function parseRules

lib/reactotron-mcp/src/redaction.ts:227–235  ·  view source on GitHub ↗
(rules: McpRedactionRules)

Source from the content-addressed store, hash-verified

225}
226
227function parseRules(rules: McpRedactionRules): ParsedRules {
228 const statePathPatterns = rules.statePathPatterns ?? []
229 return {
230 sensitiveKeysLower: new Set((rules.sensitiveKeys ?? []).map((k) => k.toLowerCase())),
231 combinedValueRegex: compileCombinedValueRegex(rules.valuePatterns ?? []),
232 statePathPatterns,
233 trackPaths: statePathPatterns.length > 0,
234 }
235}
236
237/** Per-call state threaded through recursion. */
238interface RedactionContext {

Callers 3

parsedForFunction · 0.85
redactFunction · 0.85
redactAsyncStorageDataFunction · 0.85

Calls 1

Tested by

no test coverage detected