diff --git a/src/utils/irc/__init__.py b/src/utils/irc/__init__.py index 8b2b2d05..39ee0058 100644 --- a/src/utils/irc/__init__.py +++ b/src/utils/irc/__init__.py @@ -279,8 +279,6 @@ class IRCSendBatch(IRCBatch): class Capability(object): def __init__(self, name, draft_name=None): self._caps = set([name, draft_name]) - self._name = name - self._draft_name = draft_name self._on_ack_callbacks = [] def available(self, capabilities: typing.List[str]) -> str: match = list(set(capabilities)&self._caps) @@ -288,6 +286,9 @@ class Capability(object): def enabled(self, capability: str) -> bool: return capability in self._caps + def copy(self): + return Capability(*self._caps) + def on_ack(self, callback: typing.Callable[[], None]): self._on_ack_callbacks.append(callback) def ack(self):