From 4f8df1804df03557f59bd377063f1f2195032c30 Mon Sep 17 00:00:00 2001 From: gsxdsm Date: Sat, 14 Mar 2026 14:08:15 -0700 Subject: [PATCH] Update cli/src/commands/client/plugin.ts Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> --- cli/src/commands/client/plugin.ts | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/cli/src/commands/client/plugin.ts b/cli/src/commands/client/plugin.ts index c032b988..bb54f00d 100644 --- a/cli/src/commands/client/plugin.ts +++ b/cli/src/commands/client/plugin.ts @@ -303,14 +303,15 @@ export function registerPluginCommands(program: Command): void { `/api/plugins/${encodeURIComponent(pluginKey)}`, ); + if (ctx.json) { + printOutput(result, { json: true }); + return; + } + if (!result) { console.log(pc.red(`Plugin not found: ${pluginKey}`)); process.exit(1); } - - if (ctx.json) { - printOutput(result, { json: true }); - return; } console.log(formatPlugin(result));