diff --git a/packages/astro/templates/actions.mjs b/packages/astro/templates/actions.mjs index d030c36379..dad29aa374 100644 --- a/packages/astro/templates/actions.mjs +++ b/packages/astro/templates/actions.mjs @@ -92,7 +92,7 @@ async function handleAction(param, path, context) { headers.set('Content-Length', '0'); } } - const rawResult = await fetch(`${import.meta.env.BASE_URL.replace(/\/$/, "")}/_actions/${path}`, { + const rawResult = await fetch(`${import.meta.env.BASE_URL.replace(/\/$/, '')}/_actions/${path}`, { method: 'POST', body, headers, diff --git a/packages/astro/test/actions.test.js b/packages/astro/test/actions.test.js index 2c2d3a2c31..0ed98db935 100644 --- a/packages/astro/test/actions.test.js +++ b/packages/astro/test/actions.test.js @@ -470,7 +470,7 @@ it('Base path should be used', async () => { const fixture = await loadFixture({ root: './fixtures/actions/', adapter: testAdapter(), - base: "/base" + base: '/base', }); const devServer = await fixture.startDevServer(); const formData = new FormData(); @@ -487,7 +487,7 @@ it('Base path should be used', async () => { const data = devalue.parse(await res.text()); assert.equal(data.channel, 'bholmesdev'); assert.equal(data.comment, 'Hello, World!'); - await devServer.stop() + await devServer.stop(); }); /**