Skip to content

fix: correct topUp link - #2124

Merged
seefs001 merged 2 commits into
QuantumNous:mainfrom
feitianbubu:pr/fix-topup-link
Oct 31, 2025
Merged

fix: correct topUp link#2124
seefs001 merged 2 commits into
QuantumNous:mainfrom
feitianbubu:pr/fix-topup-link

Conversation

@feitianbubu

@feitianbubu feitianbubu commented Oct 29, 2025

Copy link
Copy Markdown
Member

修复充值链接拼写错误

Summary by CodeRabbit

  • Bug Fixes
    • Updated the quota-exceeded notification link to direct users to the correct billing/top-up page.
    • Fixed the checkout cancellation redirect so users are returned to the billing/top-up page if they cancel during payment.

@coderabbitai

coderabbitai Bot commented Oct 29, 2025

Copy link
Copy Markdown
Contributor

Walkthrough

Updated two hardcoded redirect/link paths from /topup to /console/topup: one in quota notification generation and one in Stripe Checkout session CancelURL. No other logic or message content changed.

Changes

Cohort / File(s) Summary
Quota notification URL update
service/quota.go
Replaced top-up hyperlink path from /topup to /console/topup in quota-exceed notification content.
Stripe Checkout CancelURL update
controller/topup_stripe.go
Replaced Checkout session CancelURL from /topup to /console/topup when generating Stripe session params.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

  • Review focus: ensure both locations use the intended path consistently and that no environment-specific base URL assumptions are affected (e.g., front-end routing or console prefix expectations).

Possibly related PRs

Suggested reviewers

  • seefs001

Poem

🐰 I hopped through code at break of day,
A tiny path I nudged away,
From /topup now to /console/topup I steer,
A gentle hop, the users cheer! 🥕

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The PR title "fix: correct topUp link" accurately reflects the main changes in the pull request. Both modified files update topUp-related URLs, changing them from /topup to /console/topup in quota notifications and Stripe checkout cancellation redirects. The title is concise, uses standard commit conventions with the "fix:" prefix, and clearly communicates the primary intent—correcting topUp link references. A reviewer scanning the repository history would immediately understand this changeset addresses a URL path correction for topUp functionality.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 74e5e64 and 6a96dde.

📒 Files selected for processing (1)
  • controller/topup_stripe.go (1 hunks)
🧰 Additional context used
🧬 Code graph analysis (1)
controller/topup_stripe.go (1)
setting/system_setting/system_setting_old.go (1)
  • ServerAddress (3-3)
🔇 Additional comments (1)
controller/topup_stripe.go (1)

223-223: LGTM! Path correction aligns with console routing.

The CancelURL now correctly uses /console/topup, consistent with the SuccessURL pattern on line 222.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c4ea095 and 74e5e64.

📒 Files selected for processing (1)
  • service/quota.go (1 hunks)
🧰 Additional context used
🧬 Code graph analysis (1)
service/quota.go (1)
setting/system_setting/system_setting_old.go (1)
  • ServerAddress (3-3)

Comment thread service/quota.go
@seefs001

Copy link
Copy Markdown
Collaborator

顺便帮忙改一下stripe的(

@feitianbubu

Copy link
Copy Markdown
Member Author

顺便帮忙改一下stripe的(

改了 @seefs001

@seefs001

Copy link
Copy Markdown
Collaborator

顺便帮忙改一下stripe的(

改了 @seefs001

感谢

@seefs001
seefs001 merged commit 8f86215 into QuantumNous:main Oct 31, 2025
1 check passed
ennnnny pushed a commit to ennnnny/new-api that referenced this pull request Mar 17, 2026
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.

2 participants