{"version":"2.1.286","anchor":"plugin-hook-if-condition-matching-takes-a-plugin-held-flag","canonical_anchor":"plugin-hook-if-condition-matching-takes-a-plugin-held-flag","heading":"Plugin hook if conditions now match differently for some plugins","tier":"internal","area":"Hooks","url":"https:\/\/changelogs.core-directive.com\/v\/2.1.286\/e\/plugin-hook-if-condition-matching-takes-a-plugin-held-flag","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.286","markdown":"### Plugin hook `if` conditions now match differently for some plugins\n\nA hook's `if` condition now checks whether a command hook comes from a plugin that is specially marked, which can change what the condition matches\n\n**Unclear.** It is not clear what marks a plugin for this treatment or who sets that mark.\n\n**What**\n\nA hook is a command that Claude Code runs automatically at set moments, such as before a tool is used, and a hook can carry an `if` condition that decides when it fires. The way that condition is matched now takes one more input. That input is true only for command hooks that come from a plugin, and only when that plugin is marked in a particular way.\n\n- The rule matching behind `if` conditions now treats a rule with specific content as a match when that input is true.\n\n- The check against deny rules now returns a fallback answer when it cannot judge a case, instead of deciding on its own.\n\n**Why**\n\nFor hooks that come from plugins, an `if` condition may now match in cases where it did not before, so such a hook can fire more often.\n\n- Area: Hooks\n- Tier: Under the hood\n- Useful: 1\/5\n- Signal: 2\/5"}