Skip to content

Commit

Permalink
fix noop overwrite image service regression
Browse files Browse the repository at this point in the history
  • Loading branch information
alexanderniebuhr committed Oct 21, 2023
1 parent d5dc5ce commit c8db70d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 10 deletions.
5 changes: 5 additions & 0 deletions .changeset/witty-waves-rhyme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'astro': minor
---

Removes image service override, in favor to moving that logic into adapters and fix the regression it introduced
10 changes: 0 additions & 10 deletions packages/astro/src/integrations/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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;
},
Expand Down

0 comments on commit c8db70d

Please sign in to comment.