diff --git a/src/app/admin/photos/[photoId]/edit/page.tsx b/src/app/admin/photos/[photoId]/edit/page.tsx index 4ca6dcb6..b89549d5 100644 --- a/src/app/admin/photos/[photoId]/edit/page.tsx +++ b/src/app/admin/photos/[photoId]/edit/page.tsx @@ -19,9 +19,10 @@ export default async function PhotoEditPage({ const hasAiTextGeneration = AI_TEXT_GENERATION_ENABLED; - const imageThumbnailBase64 = await resizeImageFromUrl( - getNextImageUrlForRequest(photo.url, 640), - ); + // Only generate image thumbnails when AI generation is enabled + const imageThumbnailBase64 = AI_TEXT_GENERATION_ENABLED + ? await resizeImageFromUrl(getNextImageUrlForRequest(photo.url, 640)) + : ''; return (