diff --git a/functions/_middleware.js b/functions/_middleware.js deleted file mode 100644 index e5a2d4a9..00000000 --- a/functions/_middleware.js +++ /dev/null @@ -1,20 +0,0 @@ -export async function onRequest(context) { - const { env, next } = context; - - const IS_DEPRECATED = env.DEPRECATED !== 'false'; - - if (IS_DEPRECATED) { - return new Response( - 'This site has been deprecated. Please use main-site.', - { - status: 410, - headers: { - 'Content-Type': 'text/plain; charset=utf-8', - 'Cache-Control': 'no-store', - }, - } - ); - } - - return await next(); -}