src/cogs/apis.py
async def undo(self, ctx):
        """Remove your recently requested image."""
        try:
            request = self.image_cache[ctx.author.id]
        except KeyError:
            return await ctx.reply("No image to remove.")

        msg = await ctx.channel.fetch_message(request)
        await msg.delete()
        self.image_cache.pop(ctx.author.id)
Remove your recently requested image.
Remove your recently requested image.
Remove your recently requested image .
async def undo(self, ctx):
        try:
            request = self.image_cache[ctx.author.id]
        except KeyError:
            return await ctx.reply("No image to remove.")
        msg = await ctx.channel.fetch_message(request)
        await msg.delete()
        self.image_cache.pop(ctx.author.id)
async def undo ( self , ctx ) : try : request = self . image_cache [ ctx . author . id ] except KeyError : return await ctx . reply ( "No image to remove." ) msg = await ctx . channel . fetch_message ( request ) await msg . delete ( ) self . image_cache . pop ( ctx . author . id )
Remove your recently requested image.
Remove your recently requested image .
"""Remove your recently requested image."""
self
ctx