Skip to content

Commit c50362c

Browse files
committed
respect makezero linter
1 parent 1d9cd2f commit c50362c

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

internal/forwarding.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,8 @@ func leftPadIfRequired(input []byte) ([]byte, error) {
275275
return input, nil
276276
}
277277

278-
pad := make([]byte, 32-inputLen)
278+
padded := make([]byte, 32)
279+
copy(padded[32-len(input):], input)
279280

280-
return append(pad, input...), nil
281+
return padded, nil
281282
}

0 commit comments

Comments
 (0)