Example #1
0
 async def hist(self, ctx, member: discord.Member):
     '''Shows user DM logs with the bot.'''
     async for i in member.history(limit=10):
         try:
             await ctx.send(
                 f"```\nMSG: {i.content[:1000]}\n\n\nFrom: {i.author}\nEmbeds: {len(i.embeds)}\nAttachments: {len(i.attachments)}\n```",
                 files=[await n.to_file() for n in i.attachments],
                 embed=self.list_get(i.embeds, 0))
         except:
             await ctx.send("Empty Message")
Example #2
0
 async def history(self, ctx, member: discord.Member, limit=1):
     async for msg in member.history(limit=limit):
         await ctx.send(msg.content)