middeleware redirect to sign-in

Author: ignazanCreated Sep 21, 2025Updated Sep 21, 2025

Based on this in lib/payments/stripe.ts and other files and whole logic if (!team || !user) { redirect(/sign-up?redirect=checkout&priceId=${priceId}); } User with no account if select plan to subscribe redirected to sing up and after sing up to check out because price id and checkout status saved in link but middeleware in lib/auth/middele... if (!user) { redirect('/sign-in'); } and you never see that function even if you select to buy a plan without user you get redirect not to stripe checkout but after creating account just to dashborad