Skip to content

Conversation

stnguyen90
Copy link
Contributor

What does this PR do?

  • fix(billing): fix error when currentPlan or organization is undefined
  • fix(support): fix upgrade URL for free organization

Test Plan

Billing

From the /account page and with a Free org, clicked the Support button > Get Premium support button and verified the change plan page loaded successfully.

Support

From the /account page with an account with only a Pro org, clicked the Support button and confirmed the menu appeared:

Screenshot 2025-05-22 at 16 39 04

Related PRs and Issues

(If this PR is related to any other PR or resolves any issue or related to any issue link all related PR and issues here.)

Have you read the Contributing Guidelines on issues?

(Write your answer here.)

Even though upgradeURL isn't used when there are no free orgs, this line
is still evaluated and will throw an error because freeOrganization
is undefined. This commit adds a null check to prevent this error.
When going from /account to /organization/[organization]/change-plan,
the currentPlan and organization variables may not be defined as the
states are still being set. This change ensures an error isn't thrown
so that the states can update fully.
@stnguyen90 stnguyen90 requested a review from ItzNotABug May 22, 2025 23:41
@TorstenDittmann TorstenDittmann merged commit d3e8b2a into main May 25, 2025
1 of 3 checks passed
@TorstenDittmann TorstenDittmann deleted the fix-support branch May 25, 2025 17:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants