Octol1ttle
e2bf083189
This PR does numerous things to reduce method complexity: - Created an extension method `FeedbackService#SendContextualEmbedResultAsync`, which directly takes a `Result<Embed>` and checks it once in the extension method instead of multiple times in all commands; - Split the command methods for `/ban` and `/unban` into 2 parts: `Execute(Un)Ban` and `(Un)BanUserAsync`. The former will check all the needed results and will pass the outputs into the latter; - Extracted the method for logging an action into Private- and PublicFeedbackChannels. It now resides in UtilityService. Right now, only `/ban` and `/unban` make use of that method; - Created an extension method `Snowflake#EmptyOrEqualTo`, that combines the task of checking if a Snowflake is empty and checking if that Snowflake is equal to another Snowflake. Similar changes will be made to other command groups in future PRs. This is not done here to make the reviewing process easier. Signed-off-by: Octol1ttle <l1ttleofficial@outlook.com> |
||
---|---|---|
.github | ||
docs | ||
locale | ||
src | ||
.editorconfig | ||
.gitignore | ||
Boyfriend.csproj | ||
Boyfriend.sln | ||
LICENSE |
Beep! I'm a general-purpose bot for moderation written by @Octol1ttle in C# and Remora.Discord
Features
- Banning, muting, kicking, etc.
- Reminding you about something if you wish
- Reminding everyone about that new event you made
- Log everything from joining the server to deleting messages
...and more!
Installing and running Boyfriend
You can read our wiki in order to assemble your Boyfriend™ and moderate the server.
Contributing
When it comes to contributing to the project, the two main things you can do to help out are reporting issues and submitting pull requests. Please refer to the contributing guidelines to understand how to help in the most effective way possible.
Special Thanks
JetBrains, creators of ReSharper and Rider, supports Boyfriend with one of their Open Source Licenses. Rider is the recommended IDE when working with Boyfriend, and everyone on the Boyfriend team uses it. Additionally, ReSharper command-line tools made by JetBrains are used for status checks on pull requests to ensure code quality even when not using ReSharper or Rider.