fix lint UP008

This commit is contained in:
Jakub Miazek 2023-08-13 08:59:35 +02:00
parent 9436926729
commit 93a32bdd9c

View File

@ -23,7 +23,7 @@ class AuthBearer(HTTPBearer):
super().__init__(auto_error=auto_error)
async def __call__(self, request: Request):
credentials: HTTPAuthorizationCredentials = await super(AuthBearer, self).__call__(request)
credentials: HTTPAuthorizationCredentials = await super().__call__(request)
if credentials:
if not credentials.scheme == "Bearer":
raise HTTPException(status_code=403, detail="Invalid authentication scheme.")