From c8db70d9dc4534edffc831be365c3f633e78f01d Mon Sep 17 00:00:00 2001 From: Alexander Niebuhr Date: Fri, 20 Oct 2023 23:51:52 +0200 Subject: [PATCH] fix noop overwrite image service regression --- .changeset/witty-waves-rhyme.md | 5 +++++ packages/astro/src/integrations/index.ts | 10 ---------- 2 files changed, 5 insertions(+), 10 deletions(-) create mode 100644 .changeset/witty-waves-rhyme.md diff --git a/.changeset/witty-waves-rhyme.md b/.changeset/witty-waves-rhyme.md new file mode 100644 index 000000000000..f81d3965f2d9 --- /dev/null +++ b/.changeset/witty-waves-rhyme.md @@ -0,0 +1,5 @@ +--- +'astro': minor +--- + +Removes image service override, in favor to moving that logic into adapters and fix the regression it introduced diff --git a/packages/astro/src/integrations/index.ts b/packages/astro/src/integrations/index.ts index 5485794c5769..30f3314900a3 100644 --- a/packages/astro/src/integrations/index.ts +++ b/packages/astro/src/integrations/index.ts @@ -235,16 +235,6 @@ export async function runHookConfigDone({ ); } } - if (!validationResult.assets) { - logger.warn( - 'astro', - `The selected adapter ${adapter.name} does not support image optimization. To allow your project to build with the original, unoptimized images, the image service has been automatically switched to the 'noop' option. See https://docs.astro.build/en/reference/configuration-reference/#imageservice` - ); - settings.config.image.service = { - entrypoint: 'astro/assets/services/noop', - config: {}, - }; - } } settings.adapter = adapter; },