-
Notifications
You must be signed in to change notification settings - Fork 268
Cw 1063 new contacts address book flow #2322
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
base: main
Are you sure you want to change the base?
Conversation
…ub.com/cake-tech/cake_wallet into CW-1063-New-Contacts-Address-book-Flow
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.
I still have a lot of files to review, but since we want to get done with this, I will submit my review so far, and please review the code once more after your last changes and let me know
label: 'X', | ||
iconPath: 'assets/images/x_social.png', | ||
alias: '@username', | ||
supportedCurrencies: [ |
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.
should support CryptoCurrency.all
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.
We can’t use it safely because it may cause wrong validation issues — for example, Polygon could be detected as Ethereum and Doge as PIVX. I’ll reuse AddressValidator.reliableValidateCurrencies here for all cases like ‘X’ (searching inside the string). I use this list on the welcome page as well for the same reason.
lib/entities/ens_record.dart
Outdated
default: | ||
return (await ens.withName(name).getAddress()).hex; | ||
} | ||
if (coinType == CoinType.ETH) { |
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.
what about polygon? i.e || CoinType.Matic
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.
you missed this comment
onSelectedContact?.call((contact.name, contact.address)); | ||
} | ||
|
||
if (contact is (ContactRecord,String)) { |
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.
why are you returning a pair, why the address is not included in the ContactRecord class?
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.
ContactRecord doesn’t contain an address anymore — addresses are stored in parsedBlocks and manual. Here I just need to return the contact name and the address the user picked. I can either return a tuple, or return a separate map with the name and picked address
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.
why is this commented out?
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.
I didn't get what exactly needed to be fixed.
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.
why are we hiding the add to contact
bottom sheet after a successful send?
lib/entities/ens_record.dart
Outdated
default: | ||
return (await ens.withName(name).getAddress()).hex; | ||
} | ||
if (coinType == CoinType.ETH) { |
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.
you missed this comment
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.
why are we hiding the add to contact
bottom sheet after a successful send?
This reverts commit 2696b54.
Issue Number (if Applicable): Fixes #
Description
Please include a summary of the changes and which issue is fixed / feature is added.
Pull Request - Checklist