From 33775a29203628a9166d2c573d77c11c07fc28d5 Mon Sep 17 00:00:00 2001 From: Jeffrey Yasskin Date: Sun, 20 Nov 2022 21:39:20 -0800 Subject: [PATCH] Allow all redirection status codes in redirect() See https://developer.mozilla.org/en-US/docs/Web/HTTP/Status#redirection_messages for the list. --- .changeset/chilly-pumpkins-fetch.md | 5 +++++ packages/astro/src/@types/astro.ts | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 .changeset/chilly-pumpkins-fetch.md diff --git a/.changeset/chilly-pumpkins-fetch.md b/.changeset/chilly-pumpkins-fetch.md new file mode 100644 index 000000000000..f0e5ef55c821 --- /dev/null +++ b/.changeset/chilly-pumpkins-fetch.md @@ -0,0 +1,5 @@ +--- +'astro': patch +--- + +Fix redirect() typing to allow all redirection status codes. diff --git a/packages/astro/src/@types/astro.ts b/packages/astro/src/@types/astro.ts index d24b194c8c6d..5c0a19f882a5 100644 --- a/packages/astro/src/@types/astro.ts +++ b/packages/astro/src/@types/astro.ts @@ -1187,7 +1187,7 @@ interface AstroSharedContext = Record = Record>