aboutsummaryrefslogtreecommitdiffstats
path: root/bot/utils/halloween/spookifications.py
diff options
context:
space:
mode:
authorGravatar Kieran Siek <[email protected]>2019-09-14 01:09:53 +0800
committerGravatar GitHub <[email protected]>2019-09-14 01:09:53 +0800
commite1dab123fc77986b09dc622457886635eb26d4ab (patch)
treebf38f7863925b393326edf4dc04453508e545a2b /bot/utils/halloween/spookifications.py
parentMerge pull request #269 from python-discord/hacktoberfest-update (diff)
parentFix incorrect merge conflict resolutions, lint remaining items (diff)
Merge pull request #270 from python-discord/flake8-annotations
Add Flake8 annotations
Diffstat (limited to 'bot/utils/halloween/spookifications.py')
-rw-r--r--bot/utils/halloween/spookifications.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/bot/utils/halloween/spookifications.py b/bot/utils/halloween/spookifications.py
index 69b49919..11f69850 100644
--- a/bot/utils/halloween/spookifications.py
+++ b/bot/utils/halloween/spookifications.py
@@ -7,7 +7,7 @@ from PIL import ImageOps
log = logging.getLogger()
-def inversion(im):
+def inversion(im: Image) -> Image:
"""
Inverts the image.
@@ -18,7 +18,7 @@ def inversion(im):
return inv
-def pentagram(im):
+def pentagram(im: Image) -> Image:
"""Adds pentagram to the image."""
im = im.convert('RGB')
wt, ht = im.size
@@ -28,7 +28,7 @@ def pentagram(im):
return im
-def bat(im):
+def bat(im: Image) -> Image:
"""
Adds a bat silhoutte to the image.
@@ -50,7 +50,7 @@ def bat(im):
return im
-def get_random_effect(im):
+def get_random_effect(im: Image) -> Image:
"""Randomly selects and applies an effect."""
effects = [inversion, pentagram, bat]
effect = choice(effects)