Repository navigation
Commit 338610a
fix(permission): trigger permission.ask plugin hook in PermissionNext
The permission.ask hook was defined in the plugin SDK types but never
triggered in PermissionNext.ask(), preventing plugins from intercepting
permission requests.
This fix adds the Plugin.trigger() call before showing the UI prompt,
allowing plugins like oh-my-opencode to auto-approve or auto-deny
based on custom logic (e.g., PreToolUse hooks for delegation enforcement).
Fixes anomalyco#70061 parent 0b02f6d commit 338610a
1 file changed
Lines changed: 18 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
| |||
127 | 128 | | |
128 | 129 | | |
129 | 130 | | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
130 | 148 | | |
131 | | - | |
132 | | - | |
133 | | - | |
134 | | - | |
135 | 149 | | |
136 | 150 | | |
137 | 151 | | |
| |||
0 commit comments