Data API Complicance (Red 3.4) (#136)

* Simple ones first

* Less simple but still simple.

* Slightly more complicated

* use correct name

* move to module

* Black -l 120

* review

* give users the proper feedback

Co-authored-by: aikaterna <20862007+aikaterna@users.noreply.github.com>
This commit is contained in:
Draper
2020-08-26 17:57:43 +01:00
committed by GitHub
parent 4376194429
commit ae9dbf569c
95 changed files with 593 additions and 703 deletions

View File

@@ -1,5 +1,7 @@
from .partycrash import PartyCrash
__red_end_user_data_statement__ = "This cog does not persistently store data or metadata about users."
def setup(bot):
bot.add_cog(PartyCrash(bot))

View File

@@ -11,5 +11,6 @@
"tags": [
"invite"
],
"type": "COG"
"type": "COG",
"end_user_data_statement": "This cog does not persistently store data or metadata about users."
}

View File

@@ -8,6 +8,10 @@ class PartyCrash(commands.Cog):
"""Partycrash inspired by v2 Admin by Will
Does not generate invites, only lists existing invites."""
async def red_delete_data_for_user(self, **kwargs):
""" Nothing to delete """
return
def __init__(self, bot):
self.bot = bot
@@ -75,8 +79,6 @@ class PartyCrash(commands.Cog):
try:
await self._get_invites(guild, ctx)
except discord.errors.Forbidden:
return await ctx.send(
f"I don't have permission to get invites for {guild.name}."
)
return await ctx.send(f"I don't have permission to get invites for {guild.name}.")
except asyncio.TimeoutError:
return await ctx.send("No server number entered, try again later.")