Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
I updated the schemas.sql to add a
blocked
table which logs blocked member IDs, the guild their blocked from and the reason they were blocked.I then updated core.py to accept a reason argument as part of the
blacklist
command. I updated the command to add in functionality of writing to the newblocked
table however I kept in the old functionality for now. and .I then subsequently updated direct_message.py, modmail_channel.py, and tools.py to be able to read the
blocked
table entries in any places it was already checking the blacklist entries of the data table.Finally I updated core.py's
whitelist
andblacklistclear
commands to remove one and all entries respectively.Related issue(s)
#101 Add a reason for blocking users
Additional context
Add any other context or screenshots about the pull request here.