Skip to content

Commit 94d38b8

Browse files
authored
fix linting (#115)
Co-authored-by: Marko Baricevic <[email protected]>
1 parent ecbe025 commit 94d38b8

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

go/ops.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,10 @@ func (op *LeafOp) Apply(key []byte, value []byte) ([]byte, error) {
8181
// Apply will calculate the hash of the next step, given the hash of the previous step
8282
func (op *InnerOp) Apply(child []byte) ([]byte, error) {
8383
if len(child) == 0 {
84-
return nil, errors.New("Inner op needs child value")
84+
return nil, errors.New("inner op needs child value")
8585
}
86-
preimage := append(op.Prefix, child...)
86+
preimage := op.Prefix
87+
preimage = append(preimage, child...)
8788
preimage = append(preimage, op.Suffix...)
8889
return doHash(op.Hash, preimage)
8990
}

0 commit comments

Comments
 (0)