def list(self, ctx):
"""List the substitutions.
Usage: sub list"""
if len(self.bot.store['subs']) >= 1:
pager = commands.Paginator(prefix='', suffix='')
pager.add_line('Here are your substitutions:')
for idx, (name, replacement) in enumerate(self.bot.store['subs'].items()):
pager.add_line('`#' + str(idx + 1) + '`: ' + name + ' ? ' + replacement)
for page in pager.pages:
await ctx.send(page)
else:
await ctx.send('You don\'t have any substitutions!')
评论列表
文章目录