mirror of https://github.com/helm/helm.git
fix(pkg/strvals): use rune literal instead of ASCII
When checking that a value begins with zero use a rune literal instead of the ASCII code for zero.
This commit is contained in:
parent
609e72b357
commit
a5dc546726
|
@ -309,7 +309,7 @@ func typedVal(v []rune) interface{} {
|
|||
}
|
||||
|
||||
// If this value does not start with zero, try parsing it to an int
|
||||
if len(val) != 0 && val[0] != 48 {
|
||||
if len(val) != 0 && val[0] != '0' {
|
||||
if iv, err := strconv.ParseInt(val, 10, 64); err == nil {
|
||||
return iv
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue