[Commands] Cleanup #profanity Command. (#2113)

* [Commands] Cleanup #profanity Command.
- Cleanup messages and logic.

* Update profanity_manager.cpp

* Update profanity_manager.cpp

* Update profanity_manager.cpp

* Update profanity_manager.cpp
This commit is contained in:
Kinglykrab
2022-05-06 21:36:23 -04:00
committed by GitHub
parent 4eaf44fc33
commit bf1d05d639
3 changed files with 229 additions and 128 deletions
+4 -4
View File
@@ -22,6 +22,7 @@
#include <string>
#include <list>
#include <fmt/format.h>
class DBcore;
@@ -34,13 +35,12 @@ namespace EQ
static bool UpdateProfanityList(DBcore *db);
static bool DeleteProfanityList(DBcore *db);
static bool AddProfanity(DBcore *db, const char *profanity);
static bool RemoveProfanity(DBcore *db, const char *profanity);
static bool AddProfanity(DBcore *db, std::string profanity);
static bool RemoveProfanity(DBcore *db, std::string profanity);
static void RedactMessage(char *message);
static void RedactMessage(std::string &message);
static bool ContainsCensoredLanguage(const char *message);
static bool ContainsCensoredLanguage(const std::string &message);
static const std::list<std::string> &GetProfanityList();
@@ -53,7 +53,7 @@ namespace EQ
private:
static bool load_database_entries(DBcore *db);
static bool clear_database_entries(DBcore *db);
static bool check_for_existing_entry(const char *profanity);
static bool check_for_existing_entry(std::string profanity);
};