Skip to content

Commit

Permalink
Try with example
Browse files Browse the repository at this point in the history
  • Loading branch information
brachkow committed May 9, 2024
1 parent fb096de commit ced85c0
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions functions/_middleware.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,7 @@ export async function onRequest(context) {
const { pathname } = new URL(request.url);

if (pathname.startsWith('/api/')) {
return new Response.redirect(
'https://app.tough-dev.school' + pathname,
'304',
);
return new Response.redirect('http://example.com', '304');
}

return res;
Expand Down

0 comments on commit ced85c0

Please sign in to comment.