Skip to content

Commit 33f8994

Browse files
committed
fix code snippet by removing uselss async
1 parent 513a810 commit 33f8994

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/content/docs/workers/examples/respond-with-another-site.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ import { Render, TabItem, Tabs } from "~/components";
3434
```ts
3535
export default {
3636
async fetch(request): Promise<Response> {
37-
async function MethodNotAllowed(request) {
37+
function MethodNotAllowed(request) {
3838
return new Response(`Method ${request.method} not allowed.`, {
3939
status: 405,
4040
headers: {

src/content/partials/workers/respond-another-site-example-js.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
```js playground
77
export default {
88
async fetch(request) {
9-
async function MethodNotAllowed(request) {
9+
function MethodNotAllowed(request) {
1010
return new Response(`Method ${request.method} not allowed.`, {
1111
status: 405,
1212
headers: {

0 commit comments

Comments
 (0)