A fork of multiple-purpose Discord bot written in Remora.Discord
This repository has been archived on 2024-06-23. You can view files and clone it, but cannot push or open issues or pull requests.
Find a file
Octol1ttle 438ecfb41b
Force enumeration of global collections before using them (#106)
This PR closes #105 

This PR fixes exceptions caused by changing a collection's contents
while it is being enumerated. This can often happen with Guild- and
MemberDatas. By using `ToArray()` on these global collections and using
it in the `foreach` loop, we create a new copy of the collection,
preventing any modification to it.

While this does introduce a lot of memory allocations, there is no
fixing that. Usually, the fix to these exceptions would be to convert
the `foreach` to a reverse-`for`. However, because indices cannot be
used on these collections, that is not possible.

Signed-off-by: Octol1ttle <l1ttleofficial@outlook.com>
2023-09-12 16:28:46 +03:00
.github Bump actions/checkout from 3 to 4 (#104) 2023-09-11 14:20:03 +03:00
CodeAnalysis Fix JSON corruption when saving (#100) 2023-08-22 07:46:57 +00:00
docs Change organization name references from TeamOctolings to LabsDevelopment (#93) 2023-08-20 20:27:16 +00:00
locale Add failed embed for /listremind (#88) 2023-08-14 07:45:56 +00:00
src Force enumeration of global collections before using them (#106) 2023-09-12 16:28:46 +03:00
.editorconfig Add automatic deployment (#90) 2023-08-14 13:24:20 +00:00
.gitignore Switch to Remora.Discord (#41) 2023-07-09 16:32:14 +03:00
Boyfriend.csproj Change organization name references from TeamOctolings to LabsDevelopment (#93) 2023-08-20 20:27:16 +00:00
Boyfriend.sln Rename solution & project, move the project files one layer up 2023-01-18 20:17:33 +05:00
LICENSE Seal all possible classes, add LICENSE, follow async naming conventions 2022-09-18 19:41:29 +05:00

Boyfriend logo

License Workflow Status Last Commit

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 Logo (Main) logo

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.