Skip to content

Commit

Permalink
🐛 partial_emoji could be unbound
Browse files Browse the repository at this point in the history
  • Loading branch information
Paillat-dev committed Nov 7, 2024
1 parent 636273a commit 8238d7c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions discord/soundboard.py
Original file line number Diff line number Diff line change
Expand Up @@ -230,13 +230,12 @@ def edit(
"emoji_id": None,
"emoji_name": None,
}
partial_emoji = None
if emoji is not None:
if isinstance(emoji, _EmojiTag):
partial_emoji = emoji._to_partial()
elif isinstance(emoji, str):
partial_emoji = PartialEmoji.from_str(emoji)
else:
partial_emoji = None

if partial_emoji is not None:
if partial_emoji.id is None:
Expand Down

0 comments on commit 8238d7c

Please sign in to comment.