Fix 500 on settings update: include user_id in explicit SettingsResponse constructor

The W9 fix added user_id to SettingsResponse but missed the manual
_to_settings_response() builder, causing Pydantic validation failure.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Kyle 2026-02-25 08:32:52 +08:00
parent 9b261574ca
commit 6094561d74

View File

@ -17,6 +17,7 @@ def _to_settings_response(s: Settings) -> SettingsResponse:
""" """
return SettingsResponse( return SettingsResponse(
id=s.id, id=s.id,
user_id=s.user_id,
accent_color=s.accent_color, accent_color=s.accent_color,
upcoming_days=s.upcoming_days, upcoming_days=s.upcoming_days,
preferred_name=s.preferred_name, preferred_name=s.preferred_name,