From b00341083ef4a443d844bac59a0b4c178797d25f Mon Sep 17 00:00:00 2001 From: Charlie Chen Date: Wed, 20 Nov 2024 17:16:31 -0600 Subject: [PATCH] remove duplicate log fields; add some function comments to improve readibality --- zetaclient/chains/bitcoin/observer/inbound.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/zetaclient/chains/bitcoin/observer/inbound.go b/zetaclient/chains/bitcoin/observer/inbound.go index 12d7d15f46..dece5433a4 100644 --- a/zetaclient/chains/bitcoin/observer/inbound.go +++ b/zetaclient/chains/bitcoin/observer/inbound.go @@ -332,12 +332,15 @@ func FilterAndParseIncomingTx( } // GetInboundVoteFromBtcEvent converts a BTCInboundEvent to a MsgVoteInbound to enable voting on the inbound on zetacore +// +// Returns: +// - a valid MsgVoteInbound message, or +// - nil if no valid message can be created for whatever reasons: +// invalid data, not processable, invalid amount, etc. func (ob *Observer) GetInboundVoteFromBtcEvent(event *BTCInboundEvent) *crosschaintypes.MsgVoteInbound { // prepare logger fields lf := map[string]any{ - logs.FieldModule: logs.ModNameInbound, logs.FieldMethod: "GetInboundVoteFromBtcEvent", - logs.FieldChain: ob.Chain().ChainId, logs.FieldTx: event.TxHash, }