mirror of
https://github.com/myned/modufur.git
synced 2024-12-25 06:37:29 +00:00
Merge branch 'dev'
This commit is contained in:
commit
99bbd645a7
2 changed files with 6 additions and 2 deletions
|
@ -53,11 +53,13 @@ class MsG:
|
||||||
|
|
||||||
for tag in tags:
|
for tag in tags:
|
||||||
tag_request = await u.fetch('https://e621.net/tag/related.json', params={'tags': tag, 'type': 'general'}, json=True)
|
tag_request = await u.fetch('https://e621.net/tag/related.json', params={'tags': tag, 'type': 'general'}, json=True)
|
||||||
for rel in tag_request.get(tag, [None]):
|
for rel in tag_request.get(tag, []):
|
||||||
related.append(rel[0])
|
related.append(rel[0])
|
||||||
|
|
||||||
await dest.send('`{}` **related tags:**\n```\n{}```'.format(tag, formatter.tostring(related)))
|
await dest.send('`{}` **related tags:**\n```\n{}```'.format(tag, formatter.tostring(related)))
|
||||||
|
|
||||||
|
await asyncio.sleep(self.RATE_LIMIT)
|
||||||
|
|
||||||
related.clear()
|
related.clear()
|
||||||
|
|
||||||
await ctx.message.add_reaction('✅')
|
await ctx.message.add_reaction('✅')
|
||||||
|
@ -79,6 +81,8 @@ class MsG:
|
||||||
|
|
||||||
await dest.send('`{}` **aliases:**\n```\n{}```'.format(tag, formatter.tostring(aliases)))
|
await dest.send('`{}` **aliases:**\n```\n{}```'.format(tag, formatter.tostring(aliases)))
|
||||||
|
|
||||||
|
await asyncio.sleep(self.RATE_LIMIT)
|
||||||
|
|
||||||
aliases.clear()
|
aliases.clear()
|
||||||
|
|
||||||
await ctx.message.add_reaction('✅')
|
await ctx.message.add_reaction('✅')
|
||||||
|
|
|
@ -42,7 +42,7 @@ class Utils:
|
||||||
print(command_dict)
|
print(command_dict)
|
||||||
await ctx.invoke(command_dict.get(str(ctx.author.id), {}).get('command', None), args)
|
await ctx.invoke(command_dict.get(str(ctx.author.id), {}).get('command', None), args)
|
||||||
|
|
||||||
# [prefix]ping -> Pong!
|
# Displays latency
|
||||||
@commands.command(aliases=['p'], brief='Pong!', description='Returns latency from bot to Discord servers, not to user')
|
@commands.command(aliases=['p'], brief='Pong!', description='Returns latency from bot to Discord servers, not to user')
|
||||||
@checks.del_ctx()
|
@checks.del_ctx()
|
||||||
async def ping(self, ctx):
|
async def ping(self, ctx):
|
||||||
|
|
Loading…
Reference in a new issue