Infinite self redirect when opening port link on Studio

Hey! When trying to preview my NextJS project, I get a TOO MANY REDIRECTS error from the sign in page, so the bug can’t be in my code since this is a studio proxy page, here is a screenshot:

This might be this bug coming back.

1 Like

Ok, I have discovered the issue, I had a bad written middleware.ts causing the redirect!

1 Like

Good job resolving your issue, @kaiotellure . 9 out of 10 times, this issue is a result of an error in the code. Once identified and corrected, you should be good to go.