This commit is contained in:
Luna 2021-08-30 23:22:54 -03:00
parent 0c14473a95
commit 36a69ad8cb
1 changed files with 2 additions and 1 deletions

View File

@ -130,7 +130,7 @@ async def _max_role_position(guild_id, member_id) -> Optional[int]:
async def _validate_target_member(
guild_id: int, user_id: int, target_member_id: int
) -> bool:
owner_id = await storage.db.fetchval(
owner_id = await app.storage.db.fetchval(
"""
SELECT owner_id
FROM guilds
@ -138,6 +138,7 @@ async def _validate_target_member(
""",
guild_id,
)
assert owner_id is not None
# owners have all permissions
# if doing an action as an owner, it always works