mirror of
https://github.com/uhIgnacio/EmoteManager.git
synced 2024-08-15 02:23:13 +00:00
fix em/add with attachments
This commit is contained in:
parent
30c16b8b8c
commit
14a82561e7
1 changed files with 2 additions and 1 deletions
|
@ -200,7 +200,8 @@ class Emotes(commands.Cog):
|
|||
@staticmethod
|
||||
def format_emote_filename(filename):
|
||||
"""format a filename to an emote name as discord does when you upload an emote image"""
|
||||
return posixpath.splitext(filename)[0].rpartition('-')[0].replace(' ', '')
|
||||
left, sep, right = posixpath.splitext(filename)[0].rpartition('-')
|
||||
return (left or right).replace(' ', '')
|
||||
|
||||
@commands.command(name='add-from-ec', aliases=['addfromec'])
|
||||
async def add_from_ec(self, context, name, *names):
|
||||
|
|
Loading…
Reference in a new issue