From c34535496675b223e4ca383db4c8e321374c3915 Mon Sep 17 00:00:00 2001 From: Sean King Date: Fri, 11 Mar 2022 16:11:59 +0100 Subject: [PATCH] chore: comments --- modules/core/02-client/types/codec.go | 4 +++- modules/core/exported/client.go | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/core/02-client/types/codec.go b/modules/core/02-client/types/codec.go index ddc79196d0d..defdf4c3480 100644 --- a/modules/core/02-client/types/codec.go +++ b/modules/core/02-client/types/codec.go @@ -124,7 +124,9 @@ func UnpackConsensusState(any *codectypes.Any) (exported.ConsensusState, error) return consensusState, nil } -//TODO: comment +// PackClientMessage constructs a new Any packed with the given value. It returns +// an error if the value can't be casted to a protobuf message or if the concrete +// implemention is not registered to the protobuf codec. func PackClientMessage(clientMessage exported.ClientMessage) (*codectypes.Any, error) { msg, ok := clientMessage.(proto.Message) if !ok { diff --git a/modules/core/exported/client.go b/modules/core/exported/client.go index e404dc50715..6134eb52e77 100644 --- a/modules/core/exported/client.go +++ b/modules/core/exported/client.go @@ -194,7 +194,7 @@ type ConsensusState interface { ValidateBasic() error } -// TODO: comment +// ClientMessage is an interface used for Header and Misbehaviour implementations type ClientMessage interface { proto.Message