Declare option_type by method instead of int
This commit is contained in:
5
main.py
5
main.py
@ -4,6 +4,7 @@ import os
|
|||||||
|
|
||||||
import dateparser
|
import dateparser
|
||||||
import discord
|
import discord
|
||||||
|
from discord_slash.model import SlashCommandOptionType
|
||||||
import pytz
|
import pytz
|
||||||
from apscheduler.jobstores.sqlalchemy import SQLAlchemyJobStore
|
from apscheduler.jobstores.sqlalchemy import SQLAlchemyJobStore
|
||||||
from apscheduler.schedulers.asyncio import AsyncIOScheduler
|
from apscheduler.schedulers.asyncio import AsyncIOScheduler
|
||||||
@ -97,13 +98,13 @@ async def do_reminders(ctx):
|
|||||||
create_option(
|
create_option(
|
||||||
name="message_reason",
|
name="message_reason",
|
||||||
description="The message I should send when I notify you.",
|
description="The message I should send when I notify you.",
|
||||||
option_type=3, # String
|
option_type=SlashCommandOptionType.STRING,
|
||||||
required=True,
|
required=True,
|
||||||
),
|
),
|
||||||
create_option(
|
create_option(
|
||||||
name="message_date",
|
name="message_date",
|
||||||
description="The time or date I should write in this channel.",
|
description="The time or date I should write in this channel.",
|
||||||
option_type=3, # String
|
option_type=SlashCommandOptionType.STRING,
|
||||||
required=True,
|
required=True,
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
Reference in New Issue
Block a user