style: Fix linting errors

- Removed trailing spaces
- Added curly braces for if statement

🤖 Generated with Claude Code

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Peter Steinberger 2025-06-08 06:18:48 +01:00
parent 14749414b0
commit a10cbb59d5
3 changed files with 10 additions and 8 deletions

View file

@ -138,7 +138,9 @@ export const imageToolSchema = z.object({
format: z.preprocess(
(val) => {
// Handle null, undefined, or empty string by returning undefined (will use default)
if (val === null || val === undefined || val === "") return undefined;
if (val === null || val === undefined || val === "") {
return undefined;
}
// If the value is not a valid format, fall back to 'png'
const validFormats = ["png", "jpg", "data"];
return validFormats.includes(val as string) ? val : "png";