diff --git a/src/lib.rs b/src/lib.rs index dea33615a..8211686a7 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -367,6 +367,9 @@ mod contract { #[no_mangle] pub extern "C" fn new_eth_connector() { + // Only the owner can initialize the EthConnector + sdk::assert_private_call(); + EthConnectorContract::init_contract() } diff --git a/tests/test_connector.rs b/tests/test_connector.rs index ec05f65c3..d0e4bda26 100644 --- a/tests/test_connector.rs +++ b/tests/test_connector.rs @@ -100,7 +100,7 @@ fn init_contract( STORAGE_AMOUNT, ) .assert_success(); - master_account + contract_account .call( contract_name.to_string(), "new_eth_connector",