diff --git a/discord/flags.py b/discord/flags.py index 64d7a7c8b..8f77d506e 100644 --- a/discord/flags.py +++ b/discord/flags.py @@ -159,6 +159,9 @@ class BaseFlags: max_value = -1 + (2**max_bits) return self._from_value(self.value ^ max_value) + def __bool__(self) -> bool: + return self.value != self.DEFAULT_VALUE + def __eq__(self, other: object) -> bool: return isinstance(other, self.__class__) and self.value == other.value