Skip to content

Commit

Permalink
Modified bridge lib.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
andreiblt1304 committed Apr 23, 2024
1 parent a0c59e8 commit 990347d
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions esdt-safe/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,12 @@ pub trait EsdtSafe:
#[init]
fn init(
&self,
is_sovereign_chain: bool,
min_valid_signers: u32,
initiator_address: ManagedAddress,
signers: MultiValueEncoded<ManagedAddress>,
) {
self.is_sovereign_chain().set(is_sovereign_chain);
self.max_tx_batch_size().set(DEFAULT_MAX_TX_BATCH_SIZE);
self.max_tx_batch_block_duration()
.set(DEFAULT_MAX_TX_BATCH_BLOCK_DURATION);
Expand Down Expand Up @@ -70,6 +72,23 @@ pub trait EsdtSafe:
self.fee_market_address().set(fee_market_address);
}

#[only_owner]
#[endpoint(setMultisigAddress)]
fn set_multisig_address(&self, multisig_address: ManagedAddress) {
self.require_sc_address(&multisig_address);

self.multisig_address().set(multisig_address);
}

#[only_owner]
#[endpoint(setSovereignBridgeAddress)]
fn set_sovereign_bridge_address(&self, bridge_address: ManagedAddress) {
self.require_sc_address(&bridge_address);

self.sovereign_bridge_address().set(bridge_address);
}

#[endpoint]
fn upgrade(&self) {}

}

0 comments on commit 990347d

Please sign in to comment.