diff --git a/docs/tutorial/getting-started/validation/index.md b/docs/tutorial/getting-started/validation/index.md index fe2dc7b1..5e67c65c 100644 --- a/docs/tutorial/getting-started/validation/index.md +++ b/docs/tutorial/getting-started/validation/index.md @@ -134,7 +134,7 @@ new Elysia() .get('/', ({ status, set }) => { set.headers['x-powered-by'] = 'Elysia' - return status(418, 'Hello Elysia!') + return status("I'm a teapot", 'Hello Elysia!') }) .get('/docs', ({ redirect }) => redirect('https://elysiajs.com')) .listen(3000) diff --git a/docs/tutorial/patterns/macro/index.md b/docs/tutorial/patterns/macro/index.md index fcc051a6..5d305c77 100644 --- a/docs/tutorial/patterns/macro/index.md +++ b/docs/tutorial/patterns/macro/index.md @@ -64,7 +64,7 @@ new Elysia() }), // psuedo auth check beforeHandle({ cookie: { session }, status }) { - if(!session.value) return status(401) + if(!session.value) return status('Unauthorized') } }) .post('/user', ({ body }) => body, { @@ -112,7 +112,7 @@ new Elysia() .macro('isFibonacci', { body: t.Number(), beforeHandle({ body, status }) { - if(!isFibonacci(body)) return status(418) + if(!isFibonacci(body)) return status("I'm a teapot") } }) .post('/', ({ body }) => body, {