mirror of
https://github.com/withastro/astro.git
synced 2025-02-17 22:44:24 -05:00
[ci] format
This commit is contained in:
parent
57b659bd20
commit
49e3f3e9ef
1 changed files with 14 additions and 14 deletions
|
@ -238,20 +238,20 @@ export class RenderContext {
|
||||||
async #executeRewrite(reroutePayload: RewritePayload) {
|
async #executeRewrite(reroutePayload: RewritePayload) {
|
||||||
this.pipeline.logger.debug('router', 'Calling rewrite: ', reroutePayload);
|
this.pipeline.logger.debug('router', 'Calling rewrite: ', reroutePayload);
|
||||||
if (!this.pipeline.manifest.rewritingEnabled) {
|
if (!this.pipeline.manifest.rewritingEnabled) {
|
||||||
this.pipeline.logger.error(
|
this.pipeline.logger.error(
|
||||||
'router',
|
'router',
|
||||||
'The rewrite API is experimental. To use this feature, add the `rewriting` flag to the `experimental` object in your Astro config.'
|
'The rewrite API is experimental. To use this feature, add the `rewriting` flag to the `experimental` object in your Astro config.'
|
||||||
);
|
);
|
||||||
return new Response(
|
return new Response(
|
||||||
'The rewrite API is experimental. To use this feature, add the `rewriting` flag to the `experimental` object in your Astro config.',
|
'The rewrite API is experimental. To use this feature, add the `rewriting` flag to the `experimental` object in your Astro config.',
|
||||||
{
|
{
|
||||||
status: 500,
|
status: 500,
|
||||||
statusText:
|
statusText:
|
||||||
'The rewrite API is experimental. To use this feature, add the `rewriting` flag to the `experimental` object in your Astro config.',
|
'The rewrite API is experimental. To use this feature, add the `rewriting` flag to the `experimental` object in your Astro config.',
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
const [routeData, component, newURL] = await this.pipeline.tryRewrite(
|
const [routeData, component, newURL] = await this.pipeline.tryRewrite(
|
||||||
reroutePayload,
|
reroutePayload,
|
||||||
this.request,
|
this.request,
|
||||||
this.originalRoute
|
this.originalRoute
|
||||||
|
|
Loading…
Add table
Reference in a new issue