send server wallet txn for native transfer fix#8701
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
WalkthroughThis change normalizes token addresses by treating the native token address (case-insensitive match to Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes 🚥 Pre-merge checks | ✅ 1 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (1 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8701 +/- ##
=======================================
Coverage 52.72% 52.72%
=======================================
Files 934 934
Lines 62968 62968
Branches 4135 4135
=======================================
Hits 33199 33199
Misses 29671 29671
Partials 98 98
🚀 New features to boost your workflow:
|
size-limit report 📦
|
Merge activity
|
<!-- start pr-codex -->
## PR-Codex overview
This PR focuses on normalizing the token address in the `SendProjectWalletModalContent` function to ensure consistency when interacting with the contract. It simplifies the handling of the native token address and adjusts how data is passed to the mutation.
### Detailed summary
- Added `normalizedTokenAddress` to handle token address normalization.
- Adjusted the condition to check `normalizedTokenAddress` instead of `values.tokenAddress`.
- Updated the contract call to use `normalizedTokenAddress`.
- Modified the mutation to include `normalizedTokenAddress` only if it exists.
- Changed the mutation call from `void sendMutation.mutateAsync(values)` to `sendMutation.mutate(values)`.
> ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}`
<!-- end pr-codex -->
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit
* **Bug Fixes**
* Improved native token handling in the project wallet so native tokens are correctly recognized for balance display and transfers.
* More reliable token decimal detection to ensure accurate balance reads.
* Fixed send flow to reduce submission issues and make fund transfers more dependable.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2613741 to
8e9c51e
Compare
PR-Codex overview
This PR focuses on improving the handling of the token address in the
SendProjectWalletModalContentfunction by normalizing it and ensuring consistency in the mutation process.Detailed summary
tokenAddressto lowercase if it matchesNATIVE_TOKEN_ADDRESS.normalizedTokenAddressinstead ofvalues.tokenAddress.tokenAddressin the mutation payload.sendMutation.mutateAsync(values)tosendMutation.mutate(values).Summary by CodeRabbit