diff options
Diffstat (limited to '.opencode/plugins')
| -rw-r--r-- | .opencode/plugins/superpowers.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/.opencode/plugins/superpowers.js b/.opencode/plugins/superpowers.js index e547e87..223e727 100644 --- a/.opencode/plugins/superpowers.js +++ b/.opencode/plugins/superpowers.js @@ -155,6 +155,13 @@ export const SuperpowersPlugin = async ({ client, directory }) => { * equivalent of V1's experimental.chat.messages.transform. */ async function setup(ctx) { + // V1 (observed on opencode 1.18.18) also invokes default.setup, but with a + // V1-shaped ctx that lacks the skill/session domains. Detect it and return + // quietly — V1 is served entirely by the SuperpowersPlugin named export. + if (!ctx || !ctx.skill || typeof ctx.skill.transform !== 'function' || !ctx.session || typeof ctx.session.hook !== 'function') { + return; + } + // 1. Register skills (one transform; one draft.add per skill) try { const skills = []; |
