aboutsummaryrefslogtreecommitdiffstats
path: root/bot/exts/evergreen/snakes/_utils.py
diff options
context:
space:
mode:
authorGravatar Matteo Bertucci <[email protected]>2021-08-31 15:01:10 +0200
committerGravatar Matteo Bertucci <[email protected]>2021-08-31 15:01:10 +0200
commitffda1f7069065fd4ce2b2fe781fbcb5793406f99 (patch)
tree0a68152f289f4fd1a78386a3313d5cbce584bdfe /bot/exts/evergreen/snakes/_utils.py
parentMerge pull request #831 from brad90four/patch-1 (diff)
Migrate to Discord.py 2.0a0
Since the Discord.py repository has been archived, we can switch to the latest commit of 2.0a0, knowing no breaking change will occur (still pinned to the commit just in case). This commit also solves two small problems due to that fix, the avatar interface changing and Embed.name disappearing. Quite a painless migration.
Diffstat (limited to 'bot/exts/evergreen/snakes/_utils.py')
-rw-r--r--bot/exts/evergreen/snakes/_utils.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/bot/exts/evergreen/snakes/_utils.py b/bot/exts/evergreen/snakes/_utils.py
index f996d7f8..55acaf1f 100644
--- a/bot/exts/evergreen/snakes/_utils.py
+++ b/bot/exts/evergreen/snakes/_utils.py
@@ -461,7 +461,7 @@ class SnakeAndLaddersGame:
self.players.append(user)
self.player_tiles[user.id] = 1
- avatar_bytes = await user.avatar_url_as(format="jpeg", size=PLAYER_ICON_IMAGE_SIZE).read()
+ avatar_bytes = await user.display_avatar.read()
im = Image.open(io.BytesIO(avatar_bytes)).resize((BOARD_PLAYER_SIZE, BOARD_PLAYER_SIZE))
self.avatar_images[user.id] = im