Skip to content

Commit

Permalink
Merge pull request #159 from MiscGuild/fix-is-linked-discord-func
Browse files Browse the repository at this point in the history
fix: reordered code to fix is_linked_discord()
  • Loading branch information
Amxgh authored Dec 3, 2023
2 parents caeb951 + 7bfbbcd commit bd50cbe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/utils/discord_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ async def is_linked_discord(player_data: dict, user: discord.User) -> bool:
return False
if not player_data["socialMedia"]:
return False
if not player_data["socialMedia"]["links"]:
return False
if "links" not in player_data["socialMedia"]:
return False
if not player_data["socialMedia"]["links"]:
return False
if "DISCORD" not in player_data["socialMedia"]["links"]:
return False
discord = player_data["socialMedia"]["links"]["DISCORD"]
Expand Down

0 comments on commit bd50cbe

Please sign in to comment.