smart tdee
This commit is contained in:
@@ -48,7 +48,9 @@ def homelab_status() -> dict:
|
||||
@router.get("/weather")
|
||||
def weather_dashboard(
|
||||
hours_ahead: int = 12,
|
||||
days_ahead: int = 7,
|
||||
_: User = Depends(get_current_user),
|
||||
) -> dict:
|
||||
hours = max(1, min(int(hours_ahead), 48))
|
||||
return build_weather_dashboard(hours_ahead=hours)
|
||||
hours = max(1, min(int(hours_ahead), 168))
|
||||
days = max(1, min(int(days_ahead), 16))
|
||||
return build_weather_dashboard(hours_ahead=hours, days_ahead=days)
|
||||
|
||||
Reference in New Issue
Block a user