-
Notifications
You must be signed in to change notification settings - Fork 54
fix: relax preinstall rules #809
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: develop
Are you sure you want to change the base?
fix: relax preinstall rules #809
Conversation
This comment has been minimized.
This comment has been minimized.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #809 +/- ##
===========================================
- Coverage 39.68% 39.68% -0.01%
===========================================
Files 189 189
Lines 15580 15582 +2
===========================================
Hits 6183 6183
- Misses 8761 8763 +2
Partials 636 636
🚀 New features to boost your workflow:
|
| return errorsmod.Wrapf(types.ErrInvalidPreinstall, | ||
| "preinstall %s, address %s already has an account in account keeper", preinstall.Name, preinstall.Address) | ||
| if ethAcct, ok := acct.(ethermint.EthAccountI); ok { | ||
| if types.IsEmptyCodeHash(ethAcct.GetCodeHash().Bytes()) { |
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.
| if types.IsEmptyCodeHash(ethAcct.GetCodeHash().Bytes()) { | |
| if !types.IsEmptyCodeHash(ethAcct.GetCodeHash().Bytes()) { |
|
|
||
| } | ||
| // create account with the account keeper and set code hash | ||
| acct = k.accountKeeper.NewAccountWithAddress(ctx, accAddress) |
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.
with the logic, should only create new account when acct is nil, or use the acct fetched from keeper instead
Closes: #XXX
Description
For contributor use:
docs/) or specification (x/<module>/spec/)godoccomments.Unreleasedsection inCHANGELOG.mdFiles changedin the Github PR explorerFor admin use:
WIP,R4R,docs, etc)