Typehint Colour.__init__ parameter

This commit is contained in:
Rapptz 2021-08-24 03:15:28 -04:00
parent 565b41b0b2
commit 9a61a5a063

View File

@ -78,7 +78,7 @@ class Colour:
__slots__ = ('value',)
def __init__(self, value):
def __init__(self, value: int):
if not isinstance(value, int):
raise TypeError(f'Expected int parameter, received {value.__class__.__name__} instead.')