-
Notifications
You must be signed in to change notification settings - Fork 3
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
feat(AssetMigration): add implement for AssetMigration
and FunctionRestrictable
#88
base: testnet
Are you sure you want to change the base?
Conversation
c7e7e72
to
d1ae509
Compare
d1ae509
to
0330d4f
Compare
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.
Wrong storage slot
Co-authored-by: HuyHuynh <[email protected]> Signed-off-by: tu-do.ron <[email protected]>
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.
LGTM
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.
LGTM
Signed-off-by: tu-do.ron <[email protected]>
…to set whitelist, add functional pausable module
Co-authored-by: HuyHuynh <[email protected]> Signed-off-by: tu-do.ron <[email protected]>
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.
lgtm
Signed-off-by: tu-do.ron <[email protected]>
Signed-off-by: tu-do.ron <[email protected]>
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.
The implementation looks good to me but unit tests need to be added.
@@ -58,81 +61,16 @@ contract MainchainGatewayV3 is | |||
_disableInitializers(); | |||
} | |||
|
|||
fallback() external payable { |
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.
Any requirement for this? Otherwise should not remove.
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.
an attempt to reduce code size, we also do not need this function too.
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 think it's not necessary (just a few bytes) and might break things. Please do not remove it.
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 this function is kept, the current restrict logic can be bypassed using this function to create a deposit when deposit is restricted.
…fn into one, split it to other contract for testing
Description
This PR implements:
AssetMigration Module
migrateERC20
: migrate specific amount of ERC20 tokens to whitelisted address.** note **: native will be wrapped into WETH, therefore while whitelisting, ensure to whitelist wrapped ERC20 address, instead of address(0).
FunctionRestrictable Module
restrict(bytes4, uint8)
: allow pause specific function with specific token standard.Checklist