Browse Source

Remove slots from flags

Fix #7159
pull/7161/head
Rapptz 4 years ago
parent
commit
be5603141e
  1. 4
      discord/flags.py
  2. 1
      discord/permissions.py

4
discord/flags.py

@ -42,8 +42,6 @@ BF = TypeVar('BF', bound='BaseFlags')
class flag_value(Generic[BF]):
__slots__ = ('flag', '__doc__')
def __init__(self, func: Callable[[Any], int]):
self.flag = func(None)
self.__doc__ = func.__doc__
@ -69,7 +67,7 @@ class flag_value(Generic[BF]):
class alias_flag_value(flag_value):
__slots__ = ()
pass
def fill_with_flags(*, inverted: bool = False):

1
discord/permissions.py

@ -35,7 +35,6 @@ __all__ = (
# A permission alias works like a regular flag but is marked
# So the PermissionOverwrite knows to work with it
class permission_alias(alias_flag_value):
__slots__ = ('alias',)
alias: str

Loading…
Cancel
Save