Browse Source

Remove @ prefix from usernames

Discord seemed to have backtracked on this display
pull/9422/head
Rapptz 2 years ago
parent
commit
8d17aa23c9
  1. 2
      discord/member.py
  2. 2
      discord/team.py
  3. 6
      discord/user.py
  4. 2
      discord/widget.py

2
discord/member.py

@ -274,7 +274,7 @@ class Member(discord.abc.Messageable, _UserTag):
.. describe:: str(x)
Returns the member's handle (e.g. ``@user`` or ``user#discriminator``).
Returns the member's handle (e.g. ``name`` or ``name#discriminator``).
Attributes
----------

2
discord/team.py

@ -108,7 +108,7 @@ class TeamMember(BaseUser):
.. describe:: str(x)
Returns the team member's handle (e.g. ``@user`` or ``user#discriminator``).
Returns the team member's handle (e.g. ``name`` or ``name#discriminator``).
.. versionadded:: 1.3

6
discord/user.py

@ -100,7 +100,7 @@ class BaseUser(_UserTag):
def __str__(self) -> str:
if self.discriminator == '0':
return f'@{self.name}'
return self.name
return f'{self.name}#{self.discriminator}'
def __eq__(self, other: object) -> bool:
@ -319,7 +319,7 @@ class ClientUser(BaseUser):
.. describe:: str(x)
Returns the user's handle (e.g. ``@user`` or ``user#discriminator``).
Returns the user's handle (e.g. ``name`` or ``name#discriminator``).
Attributes
-----------
@ -459,7 +459,7 @@ class User(BaseUser, discord.abc.Messageable):
.. describe:: str(x)
Returns the user's handle (e.g. ``@user`` or ``user#discriminator``).
Returns the user's handle (e.g. ``name`` or ``name#discriminator``).
Attributes
-----------

2
discord/widget.py

@ -121,7 +121,7 @@ class WidgetMember(BaseUser):
.. describe:: str(x)
Returns the widget member's handle (e.g. ``@user`` or ``user#discriminator``).
Returns the widget member's handle (e.g. ``name`` or ``name#discriminator``).
Attributes
-----------

Loading…
Cancel
Save