From 488d8b576e8ba0e8d2a8673602441d2acef0abd4 Mon Sep 17 00:00:00 2001 From: "l.gabrysiak" Date: Sat, 1 Mar 2025 19:54:13 +0100 Subject: [PATCH] mod auth --- backend/open_webui/models/auths.py | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/backend/open_webui/models/auths.py b/backend/open_webui/models/auths.py index 21b64cd..32dcb01 100644 --- a/backend/open_webui/models/auths.py +++ b/backend/open_webui/models/auths.py @@ -205,14 +205,11 @@ class AuthsTable: def update_user_profile(self, id: str, name: str, profile_image_url: str, role: str) -> bool: try: with get_db() as db: - result = ( - db.query(Users) - .filter_by(id=id) - .update({ - "name": name, - "profile_image_url": profile_image_url, - "role": role}) - ) + result = db.query(Auth).filter_by(id=id).update({ + "name": name, + "profile_image_url": profile_image_url, + "role": role + }) db.commit() return True if result == 1 else False except Exception: