Skip to content

Commit

Permalink
chore: added abstract method for calling sign_claim_fee on NEAR chain
Browse files Browse the repository at this point in the history
  • Loading branch information
Ivan Frolov authored and Ivan Frolov committed Nov 28, 2024
1 parent 24ed394 commit 3552776
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion bridge-sdk/connectors/omni-connector/src/omni_connector.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ use near_primitives::views::FinalExecutionOutcomeView;
use omni_types::locker_args::{ClaimFeeArgs, StorageDepositArgs};
use omni_types::prover_args::EvmVerifyProofArgs;
use omni_types::prover_result::ProofKind;
use omni_types::Fee;
use omni_types::{locker_args::BindTokenArgs, near_events::Nep141LockerEvent, ChainKind};
use omni_types::{Fee, OmniAddress};

use evm_bridge_client::EvmBridgeClient;
use near_bridge_client::NearBridgeClient;
Expand Down Expand Up @@ -148,6 +148,17 @@ impl OmniConnector {
near_bridge_client.claim_fee(claim_fee_args).await
}

pub async fn near_sign_claim_native_fee(
&self,
nonces: Vec<u128>,
recipient: OmniAddress,
) -> Result<FinalExecutionOutcomeView> {
let near_bridge_client = self.near_bridge_client()?;
near_bridge_client
.sign_claim_native_fee(nonces, recipient)
.await
}

pub async fn init_transfer(&self, init_transfer_args: InitTransferArgs) -> Result<String> {
match init_transfer_args {
InitTransferArgs::NearInitTransfer {
Expand Down

0 comments on commit 3552776

Please sign in to comment.