We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a51ced2 commit 993457bCopy full SHA for 993457b
src/mcp/server/auth/handlers/authorize.py
@@ -244,14 +244,14 @@ async def error_response(
244
)
245
246
# Let the provider pick the next URI to redirect to
247
- response = RedirectResponse(
248
- url="", status_code=302, headers={"Cache-Control": "no-store"}
+ return RedirectResponse(
+ url=await self.provider.authorize(
249
+ client,
250
+ auth_params,
251
+ ),
252
+ status_code=302,
253
+ headers={"Cache-Control": "no-store"}
254
- response.headers["location"] = await self.provider.authorize(
- client,
- auth_params,
- )
- return response
255
256
except Exception as validation_error:
257
# Catch-all for unexpected errors
0 commit comments