Fix quote_a config not being defaulted
This commit is contained in:
parent
bc16f3258c
commit
b76160d57a
2 changed files with 3 additions and 2 deletions
|
@ -67,9 +67,9 @@ class QuoteQuota(commands.Cog):
|
||||||
):
|
):
|
||||||
"""Checks the quote quota for the quotes channel."""
|
"""Checks the quote quota for the quotes channel."""
|
||||||
now = discord.utils.utcnow()
|
now = discord.utils.utcnow()
|
||||||
oldest = now - timedelta(days=7)
|
oldest = now - timedelta(days=days)
|
||||||
await ctx.defer()
|
await ctx.defer()
|
||||||
channel = self.quotes_channel
|
channel = self.quotes_channel or discord.utils.get(ctx.guild.text_channels, name="quotes")
|
||||||
if not channel:
|
if not channel:
|
||||||
return await ctx.respond(":x: Cannot find quotes channel.")
|
return await ctx.respond(":x: Cannot find quotes channel.")
|
||||||
|
|
||||||
|
|
|
@ -29,6 +29,7 @@ try:
|
||||||
CONFIG.setdefault("ollama", {})
|
CONFIG.setdefault("ollama", {})
|
||||||
CONFIG.setdefault("rss", {"meta": {"channel": None}})
|
CONFIG.setdefault("rss", {"meta": {"channel": None}})
|
||||||
CONFIG.setdefault("screenshot", {})
|
CONFIG.setdefault("screenshot", {})
|
||||||
|
CONFIG.setdefault("quote_a", {"channel": None})
|
||||||
CONFIG.setdefault(
|
CONFIG.setdefault(
|
||||||
"server",
|
"server",
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue