fix DEV_DBG as constant not string literal

ecowitt_support
SchiZzA 2026-05-27 21:50:14 +02:00
parent e843e39ae4
commit 16a593e2a0
No known key found for this signature in database
1 changed files with 2 additions and 2 deletions

View File

@ -207,7 +207,7 @@ class WeatherDataUpdateCoordinator(DataUpdateCoordinator):
if health:
health.update_forwarding(self.windy, self.pocasi)
if (_ := checked(self.config.options.get(DEV_DBG), True)) is not None:
if checked_or(self.config.options.get(DEV_DBG), bool, False):
_LOGGER.info("Dev log (ecowitt): %s", anonymize(data))
return aiohttp.web.Response(body="OK", status=200)
@ -404,7 +404,7 @@ class WeatherDataUpdateCoordinator(DataUpdateCoordinator):
health.update_forwarding(self.windy, self.pocasi)
# Optional dev logging (keep it lightweight to avoid log spam under high-frequency updates).
if self.config.options.get("dev_debug_checkbox"):
if checked_or(self.config.options.get(DEV_DBG), bool, False):
_LOGGER.info("Dev log: %s", anonymize(data))
return aiohttp.web.Response(body="OK", status=200)