From 27a0456b2355f7d243528cdd33cceb7eb53fc8e0 Mon Sep 17 00:00:00 2001 From: Jeffery Walsh Date: Thu, 9 Feb 2023 19:10:51 -0800 Subject: [PATCH] missing struct tag + block rpeo --- packages/relayer/cli/cli.go | 6 ++++++ packages/relayer/event.go | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/packages/relayer/cli/cli.go b/packages/relayer/cli/cli.go index 1c4f0dc5be4..0fd2657bc65 100644 --- a/packages/relayer/cli/cli.go +++ b/packages/relayer/cli/cli.go @@ -357,12 +357,18 @@ func newHTTPServer(db relayer.DB, l1EthClient relayer.EthClient, l2EthClient rel return nil, err } + blockRepo, err := repo.NewBlockRepository(db) + if err != nil { + return nil, err + } + srv, err := http.NewServer(http.NewServerOpts{ EventRepo: eventRepo, Echo: echo.New(), CorsOrigins: strings.Split(os.Getenv("CORS_ORIGINS"), ","), L1EthClient: l1EthClient, L2EthClient: l2EthClient, + BlockRepo: blockRepo, }) if err != nil { return nil, err diff --git a/packages/relayer/event.go b/packages/relayer/event.go index 4e489ad2c49..8b2737aef66 100644 --- a/packages/relayer/event.go +++ b/packages/relayer/event.go @@ -53,7 +53,7 @@ type Event struct { CanonicalTokenSymbol string `json:"canonicalTokenSymbol"` CanonicalTokenName string `json:"canonicalTokenName"` CanonicalTokenDecimals uint8 `json:"canonicalTokenDecimals"` - Amount string + Amount string `json:"amount"` } // SaveEventOpts