diff --git a/discord/flags.py b/discord/flags.py index 1c2a3046e..28bdc4e9c 100644 --- a/discord/flags.py +++ b/discord/flags.py @@ -145,6 +145,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