fix: Add a value to the Transaction if token in is ETH
not only if the action is unwrap --- don't change below this line --- ENG-4260 Took 11 minutes
This commit is contained in:
@@ -109,9 +109,10 @@ impl TychoEncoder for EVMTychoEncoder {
|
|||||||
.strategy_encoder
|
.strategy_encoder
|
||||||
.encode_strategy(solution.clone())?;
|
.encode_strategy(solution.clone())?;
|
||||||
|
|
||||||
let value = match solution.native_action.as_ref() {
|
let value = if solution.given_token == self.native_address {
|
||||||
Some(NativeAction::Wrap) => solution.given_amount.clone(),
|
solution.given_amount.clone()
|
||||||
_ => BigUint::ZERO,
|
} else {
|
||||||
|
BigUint::ZERO
|
||||||
};
|
};
|
||||||
|
|
||||||
transactions.push(Transaction {
|
transactions.push(Transaction {
|
||||||
|
|||||||
Reference in New Issue
Block a user