File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
typescript/solver/solvers/hyperlane7683 Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 11import { AddressZero } from "@ethersproject/constants" ;
2- import type { MultiProvider } from "@hyperlane-xyz/sdk" ;
2+ import { type MultiProvider } from "@hyperlane-xyz/sdk" ;
33import {
44 addressToBytes32 ,
55 bytes32ToAddress ,
@@ -199,14 +199,19 @@ async function fill(
199199 filler ,
200200 ) ;
201201
202+ const value =
203+ bytes32ToAddress ( maxSpent [ index ] . token ) === AddressZero
204+ ? maxSpent [ index ] . amount
205+ : undefined ;
206+
202207 // Depending on the implementation we may call `destination.fill` directly or call some other
203208 // contract that will produce the funds needed to execute this leg and then in turn call
204209 // `destination.fill`
205210 const tx = await destination . fill (
206211 orderId ,
207212 originData ,
208213 addressToBytes32 ( fillerAddress ) ,
209- { value : maxSpent [ index ] . amount } ,
214+ { value } ,
210215 ) ;
211216
212217 const receipt = await tx . wait ( ) ;
You can’t perform that action at this time.
0 commit comments