Skip to content

Commit d6f5264

Browse files
LulalabyPaillat-dev
authored andcommitted
Revert "feat: Add mention property to BaseEmoji class" (Pycord-Development#2973)
Revert "feat: Add mention property to BaseEmoji class (Pycord-Development#2972)" This reverts commit 55efab4. (cherry picked from commit c6109a5)
1 parent 81955a7 commit d6f5264

File tree

2 files changed

+2
-12
lines changed

2 files changed

+2
-12
lines changed

CHANGELOG.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,6 @@ These changes are available on the `master` branch, but have not yet been releas
3838
- Added support for Guild Incidents via `Guild.incidents_data` and
3939
`Guild.modify_incident_actions()`.
4040
([#2955](https://github.com/Pycord-Development/pycord/pull/2955))
41-
- Added `mention` property to `BaseEmoji`.
42-
([#2972](https://github.com/Pycord-Development/pycord/pull/2972))
4341

4442
### Changed
4543

@@ -71,8 +69,6 @@ These changes are available on the `master` branch, but have not yet been releas
7169
- Fixed attributes like :attr:`Member.display_banner` being `None` when the member has
7270
no guild specific banner, but does have a global one.
7371
([#2968](https://github.com/Pycord-Development/pycord/pull/2949))
74-
- Fixed `__repr__` formatting for `AppEmoji`.
75-
([#2972](https://github.com/Pycord-Development/pycord/pull/2972))
7672

7773
### Removed
7874

discord/emoji.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050

5151

5252
class BaseEmoji(_EmojiTag, AssetMixin):
53+
5354
__slots__: tuple[str, ...] = (
5455
"require_colons",
5556
"animated",
@@ -110,13 +111,6 @@ def url(self) -> str:
110111
fmt = "gif" if self.animated else "png"
111112
return f"{Asset.BASE}/emojis/{self.id}.{fmt}"
112113

113-
@property
114-
def mention(self) -> str:
115-
"""Return a string that allows you to mention the emoji in a message."""
116-
if self.animated:
117-
return f"<a:{self.name}:{self.id}>"
118-
return f"<:{self.name}:{self.id}>"
119-
120114

121115
class GuildEmoji(BaseEmoji):
122116
"""Represents a custom emoji in a guild.
@@ -343,7 +337,7 @@ def __init__(self, *, application_id: int, state: ConnectionState, data: EmojiPa
343337
super().__init__(state=state, data=data)
344338

345339
def __repr__(self) -> str:
346-
return f"<AppEmoji id={self.id} name={self.name!r} animated={self.animated}>"
340+
return "<AppEmoji" f" id={self.id} name={self.name!r} animated={self.animated}>"
347341

348342
@property
349343
def guild(self) -> Guild:

0 commit comments

Comments
 (0)