-
Notifications
You must be signed in to change notification settings - Fork 3.3k
fix(subscriptions): fixed organization creation failure introduced by subscription updates #361
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
… subscription updates
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR Summary
This PR fixes organization creation failures by implementing proper subscription transfer and seat management functionality. The changes include new API endpoints and improved error handling for subscription operations.
- New
/api/user/subscription/[id]/transfer/route.tsimplements secure subscription transfers between users and organizations with proper validation - Refactored seat management in
/api/user/subscription/[id]/seats/route.tswith improved metadata handling and permission checks - Bug in test case
/api/user/subscription/[id]/transfer/route.test.tswhere 'should transfer a personal subscription' test expects failure (403) instead of success - Improved type safety and error handling in
team-management.tsxwith proper TypeScript types and consolidated seat management logic - Modified
auth.tsto correctly handle both team and enterprise plan subscribers for organization creation
7 file(s) reviewed, 8 comment(s)
Edit PR Review Bot Settings | Greptile
… subscription updates (#361) * fix(subscriptions): fixed organization creation failure introduced by subscription updates * cleaned up tests * run format
Description
Fixed organization creation failure introduced by subscription updates
Type of change
How Has This Been Tested?
Tested issuance of plan, and that I was prompted in team management to create an org and then once I created it I could manage the seats and have visibility into my org.
Checklist:
npm test)Security Considerations: