From d63fa84ed48cc96bf3aa931da2ee312503349167 Mon Sep 17 00:00:00 2001 From: Isaac Beh Date: Tue, 26 Nov 2024 12:34:53 +1000 Subject: [PATCH] Fixed styling --- uqcsbot/advent.py | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/uqcsbot/advent.py b/uqcsbot/advent.py index 043a3dc..f0e4385 100644 --- a/uqcsbot/advent.py +++ b/uqcsbot/advent.py @@ -575,9 +575,7 @@ async def register_command(self, interaction: discord.Interaction, aoc_name: str query = ( db_session.query(AOCRegistrations) - .filter( - AOCRegistrations.aoc_userid == AOC_id - ) + .filter(AOCRegistrations.aoc_userid == AOC_id) .one_or_none() ) if query is not None: @@ -595,7 +593,7 @@ async def register_command(self, interaction: discord.Interaction, aoc_name: str query = ( db_session.query(AOCRegistrations) .filter( - AOCRegistrations.discord_userid == discord_id, + AOCRegistrations.discord_userid == discord_id, ) .one_or_none() ) @@ -605,9 +603,7 @@ async def register_command(self, interaction: discord.Interaction, aoc_name: str ) return - db_session.add( - AOCRegistrations(aoc_userid=AOC_id, discord_userid=discord_id) - ) + db_session.add(AOCRegistrations(aoc_userid=AOC_id, discord_userid=discord_id)) db_session.commit() db_session.close() @@ -664,9 +660,7 @@ async def register_admin_command( query = ( db_session.query(AOCRegistrations) - .filter( - AOCRegistrations.aoc_userid == aoc_id - ) + .filter(AOCRegistrations.aoc_userid == aoc_id) .one_or_none() ) if query is not None: @@ -680,9 +674,7 @@ async def register_admin_command( ) return - db_session.add( - AOCRegistrations(aoc_userid=aoc_id, discord_userid=discord_id) - ) + db_session.add(AOCRegistrations(aoc_userid=aoc_id, discord_userid=discord_id)) db_session.commit() db_session.close()