We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 057a26b commit b7a8f6bCopy full SHA for b7a8f6b
discord/ui/container.py
@@ -1,7 +1,6 @@
1
from __future__ import annotations
2
3
-from functools import partial
4
-from typing import TYPE_CHECKING, ClassVar, Iterator, TypeVar
+from typing import TYPE_CHECKING, Iterator, TypeVar
5
6
from ..colour import Colour
7
from ..components import ActionRow
@@ -113,7 +112,9 @@ def add_item(self, item: Item) -> Self:
113
112
raise TypeError(f"expected Item not {item.__class__!r}")
114
115
if isinstance(item, (Button, Select)):
116
- raise TypeError(f"{item.__class__!r} cannot be added directly. Use ActionRow instead.")
+ raise TypeError(
+ f"{item.__class__!r} cannot be added directly. Use ActionRow instead."
117
+ )
118
119
item._view = self.view
120
if hasattr(item, "items"):
0 commit comments