v0.0.394
All checks were successful
Build Docker and Deploy / Run goext test-suite (push) Successful in 1m31s

This commit is contained in:
2024-02-21 18:40:42 +01:00
parent 1007f2c834
commit 8edc067a3b
2 changed files with 5 additions and 5 deletions

View File

@@ -21,11 +21,11 @@ func (t Time) Serialize() string {
func (t Time) SerializeShort() string {
if t.NanoSecond == 0 && t.Second == 0 {
return fmt.Sprintf("%04d:%02d", t.Hour, t.Minute)
return fmt.Sprintf("%02d:%02d", t.Hour, t.Minute)
} else if t.NanoSecond == 0 {
return fmt.Sprintf("%04d:%02d:%02d", t.Hour, t.Minute, t.Second)
return fmt.Sprintf("%02d:%02d:%02d", t.Hour, t.Minute, t.Second)
} else {
return fmt.Sprintf("%04d:%02d:%02d.%09d", t.Hour, t.Minute, t.Second, t.NanoSecond)
return fmt.Sprintf("%02d:%02d:%02d.%09d", t.Hour, t.Minute, t.Second, t.NanoSecond)
}
}