Skip to content

feat(wallet): open ramp url directly for cny buy in privacy wallet - #6914

Open
SeniorZhai wants to merge 1 commit into
masterfrom
feat/cny-buy-direct-url
Open

SeniorZhai wants to merge 1 commit into
masterfrom
feat/cny-buy-direct-url

Conversation

@SeniorZhai

Copy link
Copy Markdown
Member

Summary

  • In Privacy Wallet Buy (CalculateFragment), when the selected fiat currency is CNY, tapping Buy now calls proceedToBuy() directly to open the ramp web URL instead of showing the payment method options sheet (Google Pay or Card / Bank Transfer), aligning with Buy token with card ios-app#2323.
  • Non-CNY currencies in Privacy Wallet continue to present WalletBuyOptionsBottomSheetDialogFragment, and Web3 / Classic Wallet buy behavior remains unchanged.

Verification

  • ./gradlew :app:compileGooglePlayDebugKotlin — passed
  • ./gradlew :app:assembleGooglePlayDebug — passed

@gaotic

gaotic Bot commented Dec 3, 2026 •

Copy link
Copy Markdown

AI review done for 179918e in 2m 19s · 1 comment

Quality: Needs a fix for duplicate requests before merge. The Buy handler was verified in isolation, and the Android UI and live ramp flow remain unverified.

Role Model Status
Reviewer Codex codex/gpt-6.2-sol · effort high ok

@gaotic gaotic Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

AI review · Codex · 179918e

git diff --check passed. An isolated Kotlin check reproduced the CNY regression and confirmed that USD still shows the options sheet and Web3 still opens the ramp directly. The Gradle wrapper could not create its cache directory, and the installed Gradle could not resolve the Foojay plugin offline, so the app build could not be verified.

}
}
if (isWeb3) {
if (isWeb3 || fiatMoneyViewModel.currency?.name.equals("CNY", ignoreCase = true)) {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Guard the direct CNY flow against repeat taps. Buy stays enabled during deposit-address lookup and while the spinner is visible. A Kotlin check using the PR’s click handler and stubbed network calls reproduced two ramp/weburl requests from two taps. Set an in-flight guard before the first suspension and clear it in finally.

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.

1 participant