Skip to content

Commit

Permalink
fix kang adding previous emoji
Browse files Browse the repository at this point in the history
  • Loading branch information
rking32 committed May 5, 2021
1 parent 8c8fd0f commit 0ed533e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions userge/plugins/fun/kang.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,11 +77,14 @@ async def kang_(message: Message):
_emoji = args[0]

if _emoji is not None:
_saved = emoji_
for k in _emoji:
if k and k in (
getattr(emoji, a) for a in dir(emoji) if not a.startswith("_")
):
emoji_ += k
if _saved and _saved != emoji_:
emoji_ = emoji_[len(_saved):]
if not emoji_:
emoji_ = "🤔"

Expand Down

0 comments on commit 0ed533e

Please sign in to comment.