diff --git a/rollup/internal/controller/relayer/l1_relayer.go b/rollup/internal/controller/relayer/l1_relayer.go index 93bbfd068..ef3e1faa5 100644 --- a/rollup/internal/controller/relayer/l1_relayer.go +++ b/rollup/internal/controller/relayer/l1_relayer.go @@ -16,6 +16,7 @@ import ( "scroll-tech/common/types" "scroll-tech/common/utils" + rutils "scroll-tech/rollup/internal/utils" bridgeAbi "scroll-tech/rollup/abi" diff --git a/rollup/internal/utils/exchange_rate.go b/rollup/internal/utils/exchange_rate.go index c3263ff98..85a36750f 100644 --- a/rollup/internal/utils/exchange_rate.go +++ b/rollup/internal/utils/exchange_rate.go @@ -6,6 +6,8 @@ import ( "io" "net/http" "strconv" + + "github.com/scroll-tech/go-ethereum/log" ) var BinanceApiEndpoint string = "https://api.binance.com/api/v3/ticker/price?symbol=%s" @@ -21,9 +23,9 @@ func GetExchangeRateFromBinanceApi(tokenSymbolPair string) (float64, error) { return 0, fmt.Errorf("error making HTTP request: %w", err) } defer func() { - err = resp.Body.Close() + err := resp.Body.Close() if err != nil { - fmt.Println("error closing response body:", err) + log.Error("error closing response body", "err", err) } }()