mirror of
https://github.com/rzmk/learnhouse.git
synced 2025-12-19 04:19:25 +00:00
fix: ruff issues
This commit is contained in:
parent
71279a1294
commit
7daf6df5a0
7 changed files with 7 additions and 30 deletions
|
|
@ -3,9 +3,7 @@ from typing import Literal
|
|||
from uuid import uuid4
|
||||
from fastapi import HTTPException, Request, status
|
||||
from sqlmodel import Session, select
|
||||
from src import db
|
||||
from src.security.rbac.rbac import (
|
||||
authorization_verify_based_on_roles,
|
||||
authorization_verify_based_on_roles_and_authorship,
|
||||
authorization_verify_if_user_is_anon,
|
||||
)
|
||||
|
|
@ -338,7 +336,7 @@ async def rbac_check(
|
|||
if current_user.id == 0: # if user is anonymous
|
||||
return True
|
||||
else:
|
||||
res = await authorization_verify_based_on_roles_and_authorship(
|
||||
await authorization_verify_based_on_roles_and_authorship(
|
||||
request, current_user.id, "create", "user_x", db_session
|
||||
)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue