Format datetimes to ISO standard fix #145

pull/149/head
Sleevezipper 3 years ago
parent c5d5c33d87
commit 94f8d545b9

@ -25,7 +25,7 @@ namespace hass_workstation_service.Domain.Sensors
public override string GetState() public override string GetState()
{ {
return GetLastInputTime().ToString("s"); return GetLastInputTime().ToString("o", System.Globalization.CultureInfo.InvariantCulture);
} }

@ -29,7 +29,7 @@ namespace hass_workstation_service.Domain.Sensors
public override string GetState() public override string GetState()
{ {
return (DateTime.Now - TimeSpan.FromMilliseconds(GetTickCount64())).ToString("s"); return (DateTime.Now - TimeSpan.FromMilliseconds(GetTickCount64())).ToString("o", System.Globalization.CultureInfo.InvariantCulture);
} }
[DllImport("kernel32")] [DllImport("kernel32")]

Loading…
Cancel
Save