diff options
| author | 2019-05-12 10:34:50 +0200 | |
|---|---|---|
| committer | 2019-05-12 10:34:50 +0200 | |
| commit | bc844d0196f08ec414e76a5010047989fe2a7c33 (patch) | |
| tree | 9975341954b1963a5c72037281cea93566421c93 /bot/seasons/halloween/spookyavatar.py | |
| parent | Hanukkah embed (#164) (diff) | |
| parent | Revert cat-induced programming trauma (diff) | |
Merge pull request #201 from python-discord/pypi-dpy
Change d.py Dependency from GH to PyPI
Diffstat (limited to 'bot/seasons/halloween/spookyavatar.py')
| -rw-r--r-- | bot/seasons/halloween/spookyavatar.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/bot/seasons/halloween/spookyavatar.py b/bot/seasons/halloween/spookyavatar.py index 15c7c431..2cc81da8 100644 --- a/bot/seasons/halloween/spookyavatar.py +++ b/bot/seasons/halloween/spookyavatar.py @@ -37,8 +37,9 @@ class SpookyAvatar(commands.Cog): embed = discord.Embed(colour=0xFF0000) embed.title = "Is this you or am I just really paranoid?" embed.set_author(name=str(user.name), icon_url=user.avatar_url) - resp = await self.get(user.avatar_url) - im = Image.open(BytesIO(resp)) + + image_bytes = await ctx.author.avatar_url.read() + im = Image.open(BytesIO(image_bytes)) modified_im = spookifications.get_random_effect(im) modified_im.save(str(ctx.message.id)+'.png') f = discord.File(str(ctx.message.id)+'.png') |