mirror of
https://github.com/Ku6epXBOCTuK/easy-png-tools.git
synced 2026-09-17 15:06:36 +00:00
feat: add ui for new split tool
This commit is contained in:
@@ -6,7 +6,7 @@ import { defaultSchemaParams, sanitizeSchemaParams } from "../registry-schema";
|
||||
import type { ToolResult } from "./types";
|
||||
|
||||
function asImage(result: ToolResult): PixelImage {
|
||||
if (typeof result === "string") {
|
||||
if (typeof result === "string" || "files" in result) {
|
||||
throw new Error("expected an image result");
|
||||
}
|
||||
return result;
|
||||
|
||||
Reference in New Issue
Block a user