From a6c0e1ee779c7b91098b49b68226b3cd0f4d0923 Mon Sep 17 00:00:00 2001 From: bayge Date: Sun, 26 May 2024 18:27:23 -0500 Subject: [PATCH] Decapitalise the name of the tables --- cmd/ingestor.logs.ethereum/func.go | 14 +++++++------- cmd/ingestor.logs.ethereum/func_test.go | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/cmd/ingestor.logs.ethereum/func.go b/cmd/ingestor.logs.ethereum/func.go index e74e64a7..b010c118 100644 --- a/cmd/ingestor.logs.ethereum/func.go +++ b/cmd/ingestor.logs.ethereum/func.go @@ -223,37 +223,37 @@ func handleLogCallback(seawaterAddr ethCommon.Address, l ethTypes.Log, cb func(t case seawater.TopicMintPosition: a, err = seawater.UnpackMintPosition(topic1, topic2, topic3, data) logEvent("MintPosition") - table = "events_seawater_mintPosition" + table = "events_seawater_mintposition" case seawater.TopicBurnPosition: a, err = seawater.UnpackBurnPosition(topic1, topic2, data) logEvent("BurnPosition") - table = "events_seawater_burnPosition" + table = "events_seawater_burnposition" case seawater.TopicTransferPosition: a, err = seawater.UnpackTransferPosition(topic1, topic2, topic3, data) logEvent("TransferPosition") - table = "events_seawater_transferPosition" + table = "events_seawater_transferposition" case seawater.TopicUpdatePositionLiquidity: a, err = seawater.UnpackUpdatePositionLiquidity(topic1, topic2, data) logEvent("UpdatePositionLiquidity") - table = "events_seawater_updatePositionLiquidity" + table = "events_seawater_updatepositionliquidity" case seawater.TopicCollectFees: a, err = seawater.UnpackCollectFees(topic1, topic2, topic3, data) logEvent("CollectFees") - table = "events_seawater_collectFees" + table = "events_seawater_collectfees" case seawater.TopicNewPool: a, err = seawater.UnpackNewPool(topic1, topic2, topic3, data) logEvent("NewPool") - table = "events_seawater_newPool" + table = "events_seawater_newpool" case seawater.TopicCollectProtocolFees: a, err = seawater.UnpackCollectProtocolFees(topic1, topic2, data) logEvent("CollectProtocolFees") - table = "events_seawater_collectProtocolFees" + table = "events_seawater_collectprotocolfees" case seawater.TopicSwap2: a, err = seawater.UnpackSwap2(topic1, topic2, topic3, data) diff --git a/cmd/ingestor.logs.ethereum/func_test.go b/cmd/ingestor.logs.ethereum/func_test.go index c8bfb277..4c187f79 100644 --- a/cmd/ingestor.logs.ethereum/func_test.go +++ b/cmd/ingestor.logs.ethereum/func_test.go @@ -36,7 +36,7 @@ func TestHandleLogCallbackNewPool(t *testing.T) { var l ethTypes.Log assert.Nilf(t, json.NewDecoder(s).Decode(&l), "failed to decode log") handleLogCallback(seawaterAddr, l, func(table string, a any) error { - assert.Equalf(t, "events_seawater_newPool", table, "table not equal") + assert.Equalf(t, "events_seawater_newpool", table, "table not equal") // This test is captured in a unit test, so we can focus on just testing // this one field. newPool, ok := a.(*seawater.NewPool)