lock stable diffusion down to a role called stable-diffuser

This commit is contained in:
Luke Robles 2022-10-06 08:37:04 -07:00
parent e7e616a77d
commit 48212a3571

View File

@ -66,6 +66,7 @@ class ActualUtils(commands.Cog):
questions.open_ai(query),
)
@commands.has_role("stable-diffuser")
@commands.command(name="sd")
async def sd(self, ctx: commands.Context, *, prompt):
import socket
@ -111,13 +112,9 @@ class ActualUtils(commands.Cog):
"Stable diffusion isnt running right now, sorry.\n%s" % e,
)
@commands.has_role("Track day gamers")
@commands.command(name="trackdays")
async def trackdays(self, ctx: commands.Context):
role = discord.utils.find(
lambda r: r.name == "Track day gamers", ctx.message.guild.roles
)
if role not in ctx.message.author.roles:
return await ctx.send("You cant do that")
import trackdays
for track, events in trackdays.get_msreg().items():