diff options
Diffstat (limited to 'discord/colour.py')
| -rw-r--r-- | discord/colour.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/discord/colour.py b/discord/colour.py index b8ee5dae..9f104451 100644 --- a/discord/colour.py +++ b/discord/colour.py @@ -46,13 +46,16 @@ class Colour: Attributes ------------ - value : int + value: int The raw integer colour value. """ __slots__ = ('value',) def __init__(self, value): + if not isinstance(value, int): + raise TypeError('Expected int parameter, received %s instead.' % value.__class__.__name__) + self.value = value def _get_byte(self, byte): |