Quick fix to zoneId to make it set correctly
- removed local zoneId #story[761] #pair[fwy13, hba56]
This commit is contained in:
@@ -22,7 +22,7 @@ public class RaceClock {
|
|||||||
public RaceClock(GPSCoordinate gpsCoordinate){
|
public RaceClock(GPSCoordinate gpsCoordinate){
|
||||||
TimeZoneLookup timeZoneLookup = new TimeZoneLookup();
|
TimeZoneLookup timeZoneLookup = new TimeZoneLookup();
|
||||||
TimeZoneResult timeZoneResult = timeZoneLookup.getTimeZone(gpsCoordinate.getLatitude(), gpsCoordinate.getLongitude());
|
TimeZoneResult timeZoneResult = timeZoneLookup.getTimeZone(gpsCoordinate.getLatitude(), gpsCoordinate.getLongitude());
|
||||||
ZoneId zoneId = ZoneId.of(timeZoneResult.getResult());
|
zoneId = ZoneId.of(timeZoneResult.getResult());
|
||||||
LocalDateTime localDateTime = LocalDateTime.now(zoneId);
|
LocalDateTime localDateTime = LocalDateTime.now(zoneId);
|
||||||
ZonedDateTime zonedDateTime = localDateTime.atZone(zoneId);
|
ZonedDateTime zonedDateTime = localDateTime.atZone(zoneId);
|
||||||
dateTimeFormatter = DateTimeFormatter.ofPattern("dd-MM HH:mm:ss z");
|
dateTimeFormatter = DateTimeFormatter.ofPattern("dd-MM HH:mm:ss z");
|
||||||
|
|||||||
Reference in New Issue
Block a user