MCPcopy Create free account
hub / github.com/codeaashu/claude-code / sameIf

Function sameIf

src/utils/hooks/hooksSettings.ts:43–44  ·  view source on GitHub ↗
(x: { if?: string }, y: { if?: string })

Source from the content-addressed store, hash-verified

41 // `if` is part of identity: same command with different `if` conditions
42 // are distinct hooks (e.g., setup.sh if=Bash(git *) vs if=Bash(npm *)).
43 const sameIf = (x: { if?: string }, y: { if?: string }) =>
44 (x.if ?? '') === (y.if ?? '')
45 switch (a.type) {
46 case 'command':
47 // shell is part of identity: same command string with different

Callers 1

isHookEqualFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected