Skip to content

Commit c524f65

Browse files
authored
Use human_join internal helper in BaseChannelTransformer
1 parent 2bcbd49 commit c524f65

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

discord/app_commands/transformers.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
from ..abc import GuildChannel
5353
from ..threads import Thread
5454
from ..enums import Enum as InternalEnum, AppCommandOptionType, ChannelType, Locale
55-
from ..utils import MISSING, maybe_coroutine
55+
from ..utils import MISSING, maybe_coroutine, _human_join
5656
from ..user import User
5757
from ..role import Role
5858
from ..member import Member
@@ -631,7 +631,7 @@ def __init__(self, *channel_types: Type[Any]) -> None:
631631
display_name = channel_types[0].__name__
632632
types = CHANNEL_TO_TYPES[channel_types[0]]
633633
else:
634-
display_name = '{}, and {}'.format(', '.join(t.__name__ for t in channel_types[:-1]), channel_types[-1].__name__)
634+
display_name = _human_join([t.__name__ for t in channel_types])
635635
types = []
636636

637637
for t in channel_types:

0 commit comments

Comments
 (0)