MCPcopy Index your code
hub / github.com/codeaashu/claude-code / matchesParam

Function matchesParam

src/tools/PowerShellTool/pathValidation.ts:772–782  ·  view source on GitHub ↗

* Checks if a lowercase parameter name (with leading dash) matches any entry * in the given param list, accounting for PowerShell's prefix-matching behavior * (e.g., -Lit matches -LiteralPath).

(paramLower: string, paramList: string[])

Source from the content-addressed store, hash-verified

770 * (e.g., -Lit matches -LiteralPath).
771 */
772function matchesParam(paramLower: string, paramList: string[]): boolean {
773 for (const p of paramList) {
774 if (
775 p === paramLower ||
776 (paramLower.length > 1 && p.startsWith(paramLower))
777 ) {
778 return true
779 }
780 }
781 return false
782}
783
784/**
785 * Returns true if a colon-syntax value contains expression constructs that

Callers 1

extractPathsFromCommandFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected