Skip to content

Commit

Permalink
[Staking SC] Fix remove_pair
Browse files Browse the repository at this point in the history
  • Loading branch information
catalinnnn committed Apr 5, 2021
1 parent 7a516d7 commit 1501e17
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions elrond_dex_staking/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ pub trait Staking {
let caller = self.get_caller();
let router = self.router_address().get();
require!(caller == router, "Permission denied");
self.clear_pair_for_lp_token(&token, &address);
self.clear_lp_token_for_pair(&address, &token);
self.clear_pair_for_lp_token(&token);
self.clear_lp_token_for_pair(&address);
Ok(())
}

Expand Down Expand Up @@ -413,7 +413,7 @@ pub trait Staking {
fn set_pair_for_lp_token(&self, lp_token: &TokenIdentifier, pair_address: &Address);

#[storage_clear("pair_for_lp_token")]
fn clear_pair_for_lp_token(&self, lp_token: &TokenIdentifier, pair_address: &Address);
fn clear_pair_for_lp_token(&self, lp_token: &TokenIdentifier);


#[view(getLpTokenForPair)]
Expand All @@ -427,7 +427,7 @@ pub trait Staking {
fn is_empty_lp_token_for_pair(&self, pair_address: &Address) -> bool;

#[storage_clear("lp_token_for_pair")]
fn clear_lp_token_for_pair(&self, pair_address: &Address, token: &TokenIdentifier);
fn clear_lp_token_for_pair(&self, pair_address: &Address);


#[view(getWegldTokenIdentifier)]
Expand Down

0 comments on commit 1501e17

Please sign in to comment.