Skip to content

Commit 1bae6ba

Browse files
committed
go fix
1 parent ff106ec commit 1bae6ba

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

value.go

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,10 +91,7 @@ func (v Value) Format(f fmt.State, verb rune) {
9191
if f.Flag('0') && !f.Flag('-') {
9292
padchar = '0'
9393
}
94-
padlen := wid - buflen
95-
if padlen < 0 {
96-
padlen = 0
97-
}
94+
padlen := max(wid-buflen, 0)
9895

9996
var out []byte
10097
if f.Flag('-') {

0 commit comments

Comments
 (0)