diff --git a/src/fabledassistant/routes/briefing.py b/src/fabledassistant/routes/briefing.py index 5943241..238fa11 100644 --- a/src/fabledassistant/routes/briefing.py +++ b/src/fabledassistant/routes/briefing.py @@ -130,7 +130,15 @@ async def recent_items(): @_REQUIRE async def get_weather(): rows = await weather_svc.get_cached_weather_rows(g.user.id) - temp_unit = await get_setting(g.user.id, "temperature_unit", "C") + import json as _json + raw = await get_setting(g.user.id, "briefing_config", "{}") + try: + _cfg = _json.loads(raw) if isinstance(raw, str) else (raw or {}) + temp_unit = _cfg.get("temp_unit", "C") + if temp_unit not in ("C", "F"): + temp_unit = "C" + except Exception: + temp_unit = "C" cards = [ card for row in rows if (card := weather_svc.parse_weather_card_data(row, temp_unit)) is not None