Red-DiscordBot
Red-DiscordBot copied to clipboard
Allow tempban by ID and ban downgrade
Description of the changes
- tempban will allow banning user by ID
- If using the command would cause a downgrade from permanent ban to temporary ban, a prompt will appear asking if command invoker wants to proceed
- If the user is already tempbanned, a prompt will appear asking if command invoker wants to update the duration of the current tempban.
- Prompt will be skipped if
ctx.assume_yesevaluates toTrue
Fixes #5915
Have the changes in this PR been tested?
Yes.
Additional Notes
This is my first PR to this repo and I'm quite new to Python. Suggestions for improvement to my PR are very welcome.
- Prompt will be skipped if
ctx.assume_yesevaluates toTrue
I don't think allowing tempban to be run on a schedule would be best here.
I don't think allowing tempban to be run on a schedule would be best here.
I'm only implementing this based on Jack's last statement in the issue discussion, it can be raised for discussion again if needed.
I personally think it's okay to include it since prompt only appear if user is already banned anyway, my concern is that whether it should be the default choice to downgrade instead of skipping it completely.
- Prompt will be skipped if
ctx.assume_yesevaluates toTrueI don't think allowing tempban to be run on a schedule would be best here.
It's not for scheduling, it's to allow for implementing a command that skips the prompt if someone prefers it that way.