diff --git a/b0esche_cloud/lib/widgets/account_settings_dialog.dart b/b0esche_cloud/lib/widgets/account_settings_dialog.dart index 9aedce7..1d73054 100644 --- a/b0esche_cloud/lib/widgets/account_settings_dialog.dart +++ b/b0esche_cloud/lib/widgets/account_settings_dialog.dart @@ -159,6 +159,9 @@ class _AccountSettingsDialogState extends State { ScaffoldMessenger.of(context).showSnackBar( const SnackBar(content: Text('Profile updated successfully')), ); + + // Close the dialog + Navigator.of(context).pop(); } } catch (e) { print('DEBUG: _updateProfile error: $e'); diff --git a/go_cloud/internal/http/routes.go b/go_cloud/internal/http/routes.go index 94a5337..ffffedc 100644 --- a/go_cloud/internal/http/routes.go +++ b/go_cloud/internal/http/routes.go @@ -3857,7 +3857,6 @@ func getUserProfileHandler(w http.ResponseWriter, r *http.Request, db *database. // updateUserProfileHandler updates the current user's profile information func updateUserProfileHandler(w http.ResponseWriter, r *http.Request, db *database.DB, auditLogger *audit.Logger) { - log.Printf("DEBUG: updateUserProfileHandler called") userIDStr, ok := middleware.GetUserID(r.Context()) if !ok { errors.WriteError(w, errors.CodeUnauthenticated, "Unauthorized", http.StatusUnauthorized) @@ -3881,8 +3880,6 @@ func updateUserProfileHandler(w http.ResponseWriter, r *http.Request, db *databa return } - log.Printf("DEBUG: updateUserProfileHandler req: displayName=%v, email=%v, avatarUrl=%v", req.DisplayName, req.Email, req.AvatarURL) - // Build dynamic update query var setParts []string var args []interface{} diff --git a/go_cloud/migrations/0011_add_updated_at.sql b/go_cloud/migrations/0011_add_updated_at.sql new file mode 100644 index 0000000..37bbdeb --- /dev/null +++ b/go_cloud/migrations/0011_add_updated_at.sql @@ -0,0 +1 @@ +ALTER TABLE users ADD COLUMN updated_at TIMESTAMP WITH TIME ZONE DEFAULT NOW(); \ No newline at end of file