Allow for internal time data debug.

This commit is contained in:
Captain ALM 2024-09-26 22:16:01 +01:00
parent 2281ef31f1
commit 6da8290c04
Signed by: alfred
GPG Key ID: 4E4ADD02609997B1

View File

@ -1,6 +1,7 @@
package internal
import (
"encoding/base64"
"encoding/xml"
"errors"
"fmt"
@ -353,7 +354,7 @@ type Time time.Time
func (t *Time) UnmarshalText(b []byte) error {
tt, err := http.ParseTime(string(b))
if err != nil {
return err
return errors.Join(err, errors.New("time_data : "+base64.StdEncoding.EncodeToString(b)))
}
*t = Time(tt)
return nil