Skip to content

Commit

Permalink
AAAAAAAAAAAAAAA
Browse files Browse the repository at this point in the history
  • Loading branch information
timelessnesses committed Mar 1, 2024
1 parent 2846b68 commit 6a4c9ea
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/views/folder.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ async def a():
role = await d.fetch("SELECT username, roles FROM users WHERE session = $1", str(app.storage.user["authenticator"]), record_class=UserRecord)
accessers = await d.fetch("SELECT accessers FROM folders WHERE id = $1", folder_id, record_class=FolderRecord)
print(role, accessers)
print(role[0].roles == "admin", role[0].username in accessers[0].accessers)
if role[0].username not in accessers[0].accessers or role[0].roles != "admin":
await show_header(db, f"Inaccessible Folder")
with ui.card().classes("absolute-center"):
Expand Down

0 comments on commit 6a4c9ea

Please sign in to comment.