Submitted by ladboy233, also found by gzeon
https://github.com/code-423n4/2022-11-redactedcartel/blob/03b71a8d395c02324cb9fdaf92401357da5b19d1/src/vaults/AutoPxGmx.sol#L18
https://github.com/code-423n4/2022-11-redactedcartel/blob/03b71a8d395c02324cb9fdaf92401357da5b19d1/src/vaults/AutoPxGmx.sol#L96
https://github.com/code-423n4/2022-11-redactedcartel/blob/03b71a8d395c02324cb9fdaf92401357da5b19d1/src/vaults/AutoPxGmx.sol#L268
I want to quote from the doc:
This shows that the projects is intended to support Avalanche side-chain.
SWAP_ROUTER in the AutoPxGmx.sol is hardcoded as:
But this address is the Uniswap V3 router address in arbitrium, but it is a EOA address in Avalanche,
https://snowtrace.io/address/0x68b3465833fb72a70ecdf485e0e4c7bd8665fc45
Then the AutoPxGmx.sol is not working in Avalanche.
The code below reverts because the EOA address on Avalanche does not have exactInputSingle method in compound method.
We recommend the project not hardcode the SWAP_ROUTERin AutoPxGmx.sol, can pass this parameter in the constructor.
kphed (Redacted Cartel) commented:
