@clawdreyhepburn/carapace 1.0.1 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/index.ts +2 -2
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -105,8 +105,8 @@ export default function register(api: OpenClawPluginApi) {
|
|
|
105
105
|
};
|
|
106
106
|
|
|
107
107
|
// --- Register before_tool_call hook ---
|
|
108
|
-
if (api.
|
|
109
|
-
api.
|
|
108
|
+
if (api.on) {
|
|
109
|
+
api.on("before_tool_call", async (event: any) => {
|
|
110
110
|
const toolName: string = event.toolName ?? event.tool ?? event.name ?? "";
|
|
111
111
|
const params: Record<string, unknown> = event.params ?? event.arguments ?? event.input ?? {};
|
|
112
112
|
|