Skip to content

Commit eaa61af

Browse files
committed
feat: bump version to 0.0.5 and refactor code execution plugin for improved readability
1 parent 02f5cea commit eaa61af

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/plugin-code-execution/deno.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@mcpc/plugin-code-execution",
3-
"version": "0.0.4",
3+
"version": "0.0.5",
44
"repository": {
55
"type": "git",
66
"url": "git+https://github.com/mcpc-tech/mcpc.git"

packages/plugin-code-execution/src/plugin.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ export function createCodeExecutionPlugin(
7777
const contentParts: CallToolResult["content"] = [];
7878

7979
// Execute code
80-
if (code) {
80+
if (code && hasDefinitions.length > 0) {
8181
if (!executor) throw new Error("Sandbox not initialized");
8282

8383
const result = await executor.executeCode(code, hasDefinitions);

0 commit comments

Comments
 (0)