mirror of
https://github.com/rancher/rke.git
synced 2025-09-01 06:56:29 +00:00
vendor change
This commit is contained in:
committed by
Alena Prokharchyk
parent
5153dfd8b8
commit
88449ec73b
8
vendor/github.com/prometheus/common/model/time.go
generated
vendored
8
vendor/github.com/prometheus/common/model/time.go
generated
vendored
@@ -150,13 +150,7 @@ func (t *Time) UnmarshalJSON(b []byte) error {
|
||||
return err
|
||||
}
|
||||
|
||||
// If the value was something like -0.1 the negative is lost in the
|
||||
// parsing because of the leading zero, this ensures that we capture it.
|
||||
if len(p[0]) > 0 && p[0][0] == '-' && v+va > 0 {
|
||||
*t = Time(v+va) * -1
|
||||
} else {
|
||||
*t = Time(v + va)
|
||||
}
|
||||
*t = Time(v + va)
|
||||
|
||||
default:
|
||||
return fmt.Errorf("invalid time %q", string(b))
|
||||
|
Reference in New Issue
Block a user