Skip to content

Commit

Permalink
syntax error
Browse files Browse the repository at this point in the history
  • Loading branch information
JarbasAl committed Aug 16, 2024
1 parent 76ed5f3 commit 733a3d4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ovos_gui_plugin_shell_companion/brightness.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def __init__(self, bus, config: dict):

self.default_brightness = self.config.get("default_brightness", 100)
self._brightness_level: int = self.default_brightness
self.sunrise_time, self.sunset_time = self.get_suntimes()
self.sunrise_time, self.sunset_time = None, None

self.discover()

Expand Down Expand Up @@ -396,8 +396,8 @@ def get_suntimes(self) -> Tuple[datetime.datetime, datetime.datetime]:
if reference > sunset_time: # get next sunset, today's already happened
sunset_time = s2["sunset"]

if self.sunrise_time != sunrise_time:
if self.sunrise_time is None or self.sunrise_time != sunrise_time:
LOG.info(f"Sunrise time: {sunrise_time}")
if self.sunset_time != sunset_time:
if self.sunset_time is None or self.sunset_time != sunset_time:
LOG.info(f"Sunset time: {sunset_time}")
return sunrise_time, sunset_time

0 comments on commit 733a3d4

Please sign in to comment.