Skip to content

Commit

Permalink
fix: missing timezone data on timestamp (#127)
Browse files Browse the repository at this point in the history
  • Loading branch information
firstof9 authored Jan 10, 2025
1 parent 69d908a commit a7645b8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions custom_components/gasbuddy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

import asyncio
import logging
from datetime import datetime, timedelta
from datetime import datetime, timedelta, timezone

from gasbuddy import GasBuddy # pylint: disable=import-self

Expand Down Expand Up @@ -182,5 +182,5 @@ async def _async_update_data(self) -> dict:
except Exception as exception:
raise UpdateFailed() from exception

self._data["last_updated"] = datetime.now()
self._data["last_updated"] = datetime.now(timezone.utc)
return self._data

0 comments on commit a7645b8

Please sign in to comment.