diff --git a/ledger/byron/byron.go b/ledger/byron/byron.go index 66db7b47..4ed6dae5 100644 --- a/ledger/byron/byron.go +++ b/ledger/byron/byron.go @@ -772,7 +772,9 @@ func NewByronTransactionFromCbor(data []byte) (*ByronTransaction, error) { return &byronTx, nil } -func NewByronTransactionOutputFromCbor(data []byte) (*ByronTransactionOutput, error) { +func NewByronTransactionOutputFromCbor( + data []byte, +) (*ByronTransactionOutput, error) { var byronTxOutput ByronTransactionOutput if _, err := cbor.Decode(data, &byronTxOutput); err != nil { return nil, fmt.Errorf("decode Byron transaction output error: %w", err) diff --git a/ledger/tx_test.go b/ledger/tx_test.go index 7557c495..2f108291 100644 --- a/ledger/tx_test.go +++ b/ledger/tx_test.go @@ -45,7 +45,10 @@ func TestDetermineTransactionType(t *testing.T) { } tmpTxType, err := ledger.DetermineTransactionType(txCbor) if err != nil { - t.Fatalf("DetermineTransactionType failed with an unexpected error: %s", err) + t.Fatalf( + "DetermineTransactionType failed with an unexpected error: %s", + err, + ) } if tmpTxType != testDef.expectedTxType { t.Fatalf( diff --git a/protocol/chainsync/messages_test.go b/protocol/chainsync/messages_test.go index dc06d0f0..c8cea138 100644 --- a/protocol/chainsync/messages_test.go +++ b/protocol/chainsync/messages_test.go @@ -206,7 +206,9 @@ func TestMsgRollForwardNodeToNode_CorruptedCBOR(t *testing.T) { ) if err == nil { - t.Fatalf("expected error from NewMsgRollForwardNtN with corrupted CBOR, got nil") + t.Fatalf( + "expected error from NewMsgRollForwardNtN with corrupted CBOR, got nil", + ) } } func TestMsgRollForwardNodeToClient(t *testing.T) { diff --git a/protocol/chainsync/wrappers.go b/protocol/chainsync/wrappers.go index 7ec47b08..dccdde6b 100644 --- a/protocol/chainsync/wrappers.go +++ b/protocol/chainsync/wrappers.go @@ -68,7 +68,10 @@ func NewWrappedHeader( // Parse block and extract header tmp := []cbor.RawMessage{} if _, err := cbor.Decode(blockCbor, &tmp); err != nil { - return nil, fmt.Errorf("CBOR decode failed in NewWrappedHeader: %w", err) + return nil, fmt.Errorf( + "CBOR decode failed in NewWrappedHeader: %w", + err, + ) } if len(tmp) == 0 { return nil, errors.New("decoded CBOR header is empty")