Skip to content
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

Chore/improve eth contracts #69

Open
wants to merge 15 commits into
base: master
Choose a base branch
from
Open

Conversation

fcavazzoli
Copy link
Contributor

@fcavazzoli fcavazzoli commented Nov 2, 2022

Description

ETH Proxy:

  • Add Ownable
  • Add Pausable
  • Emit Init event with constructor params.
  • Lock solidity version to 0.8.17
  • Improve overall testing

ERC20 Proxy

  • Add Ownable
  • Add Pausable
  • Add Whitelist of tokens (only Owner can modify this list)
  • Add Blacklist of tokens (only owner can modify this list)
  • Lock Solidity version to 0.8.17
  • Emit init event with constructor params
  • Improve overall testing.

@@ -67,27 +67,26 @@ contract Terabethia is Initializable, ITerabethiaCore {
external
returns (bytes32)
{
simpleStorage().nonce += 1;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is a PR open for this change already #27

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, Its the fist commit of this branch I used it as base

@@ -27,19 +35,14 @@ contract EthProxy {
terabethiaCore.consumeMessage(CANISTER_ADDRESS, payload);

// withdraw eth
require(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any reason this condition was removed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, cause it is useless, its gonna fail anyways

@@ -61,4 +64,27 @@ contract EthProxy {
// Send the message to the IC
terabethiaCore.sendMessage(CANISTER_ADDRESS, payload);
}

function send(address recipient, uint256 amount)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is this function for? Also does just give arbitrary ownership of all funds in the contract to the owner?

@dtilve
Copy link

dtilve commented Nov 8, 2022

can we merge this? 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants