95 @app_commands.guilds(cfg.guild_id)
96 @app_commands.command(description="Set your birthday. The birthday role will be given to you on that day.")
97 @app_commands.describe(month="The month you were born in")
98 @app_commands.choices(month=[app_commands.Choice(name=m, value=m) for m in MONTH_MAPPING.keys()]) 99 @app_commands.describe(date="The date you were born on")
100 @app_commands.autocomplete(date=date_autocompleter)
101 @transform_context
Consider iterating the dictionary directly instead of calling .keys()
.
Using for key in dictionary
would always iterate the dictionary keys.
sounds = {"cow": "moo", "dog": "bark"}
for key in sounds.keys():
print(key)
sounds = {"cow": "moo", "dog": "bark"}
for key in sounds:
print(key)