From 4b7403496795fd7476243e7b6a48292c0cfe1b4b Mon Sep 17 00:00:00 2001 From: Taylor Wilsdon Date: Sun, 19 Oct 2025 16:58:09 -0400 Subject: [PATCH] black fmt --- backend/open_webui/utils/oauth.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/backend/open_webui/utils/oauth.py b/backend/open_webui/utils/oauth.py index d24a379ede..34fb441679 100644 --- a/backend/open_webui/utils/oauth.py +++ b/backend/open_webui/utils/oauth.py @@ -486,9 +486,7 @@ class OAuthClientManager: try: payload = json.loads(body_text) error = payload.get("error") - error_description = payload.get( - "error_description", "" - ) + error_description = payload.get("error_description", "") except json.JSONDecodeError: error = None error_description = "" @@ -496,7 +494,11 @@ class OAuthClientManager: error_description = body_text combined = f"{error or ''} {error_description}".lower() - if "invalid_client" in combined or "invalid client" in combined or "client id" in combined: + if ( + "invalid_client" in combined + or "invalid client" in combined + or "client id" in combined + ): log.warning( "OAuth client preflight detected invalid registration for %s: %s %s", client_info.client_id, @@ -577,9 +579,7 @@ class OAuthClientManager: log.info("Re-registered OAuth client %s for MCP tool server", client_id) return True - async def _ensure_valid_client_registration( - self, request, client_id: str - ) -> None: + async def _ensure_valid_client_registration(self, request, client_id: str) -> None: if not client_id.startswith("mcp:"): return