-
Notifications
You must be signed in to change notification settings - Fork 172
fix: address feedback on large-wallet changes #1388
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
WalkthroughThis update refactors thread safety and error handling in several wallet components. It marks Changes
Sequence Diagram(s)sequenceDiagram
participant UI as SendCoinsFragment
participant VM as SendCoinsViewModel
UI->>VM: setAmount(amount)
VM->>VM: Update _currentAmount StateFlow
Note over VM: Debounce 150ms
VM->>VM: Execute dry run (after debounce)
sequenceDiagram
participant Activity as MainActivity
participant Dialog as MixDashFirstDialogFragment
participant CreateUsername as CreateUsernameActivity
Activity->>Dialog: show(activity, onConfirm)
Dialog-->>Activity: onConfirm callback invoked
Activity->>CreateUsername: startActivity()
Possibly related PRs
Suggested reviewers
Poem
Tip ⚡️ Faster reviews with caching
Enjoy the performance boost—your workflow just got faster. 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (3)
🚧 Files skipped from review as they are similar to previous changes (2)
⏰ Context from checks skipped due to timeout of 90000ms (1)
🔇 Additional comments (1)
✨ Finishing Touches
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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
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.
Actionable comments posted: 2
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
wallet/src/de/schildbach/wallet/service/BlockchainServiceImpl.kt
(1 hunks)wallet/src/de/schildbach/wallet/ui/main/MainActivity.kt
(1 hunks)wallet/src/de/schildbach/wallet/ui/more/MixDashFirstDialogFragment.kt
(3 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: build
🔇 Additional comments (2)
wallet/src/de/schildbach/wallet/service/BlockchainServiceImpl.kt (1)
1053-1053
: Improved null safety handling.The change from
wallet!!.reset()
towallet?.reset()
prevents potential null pointer exceptions by only calling the reset method if the wallet instance is not null. This is aligned with Kotlin best practices and makes the code more robust.wallet/src/de/schildbach/wallet/ui/main/MainActivity.kt (1)
260-262
: Flow improvement with callback-based dialog interactionThe code now correctly uses a callback approach for dialog interaction, deferring the CreateUsernameActivity start until after dialog confirmation. This is a good improvement in control flow.
Issue being fixed or feature implemented
Related PR's and Dependencies
Screenshots / Videos
How Has This Been Tested?
Checklist:
Summary by CodeRabbit