fix(mcp): type the input refusal as the Error it is, so the strict build reads it

This commit is contained in:
Maurice
2026-11-23 16:29:35 +01:00
parent 96fa7ca4e8
commit 0fe536bbd2
+1 -1
View File
@@ -61,7 +61,7 @@ function mapValidated(
mapper: McpInputMapper,
input: unknown,
shape: Record<string, z.ZodType> | undefined,
refuse: (message: string) => McpError,
refuse: (message: string) => Error,
): unknown {
const mapped = mapper(input);
if (mapped === input || !shape || !isRecord(input) || !isRecord(mapped)) return mapped;