1
0

Update module prometheus/client_golang to v0.9.4 (#245)

Update module prometheus/client_golang to v0.9.4

Reviewed-on: https://kolaente.dev/vikunja/api/pulls/245
This commit is contained in:
renovate
2020-04-07 20:42:06 +00:00
committed by konrad
parent 76f19db6e7
commit dda558fe1c
51 changed files with 3009 additions and 2248 deletions

View File

@ -150,7 +150,13 @@ func (t *Time) UnmarshalJSON(b []byte) error {
return err
}
*t = Time(v + va)
// 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)
}
default:
return fmt.Errorf("invalid time %q", string(b))