Incorrect inbound_confirmation_blocks calculation in Swap Quote for ETH source token
A total_swap_seconds param in response uses the inboundConfirmations param for its calculation. If the source token is from ETH chain and the destination is the THOR chain when the calculation is wrong and always equals 24 seconds (because inboundConfirmations = 2 all the time).
Look at https://gitlab.com/thorchain/thornode/-/blob/v1.131.0/x/thorchain/querier_quotes.go#L430 :
// min confirmation adjustment
if chain.Equals(common.ETHChain) || chain.Equals(common.DOGEChain) && confirmations < 2 {
confirmations = 2
}
I think the condition is missing parentheses:
// min confirmation adjustment
if (chain.Equals(common.ETHChain) || chain.Equals(common.DOGEChain)) && confirmations < 2 {
confirmations = 2
}
Edited by Acme