diff --git a/globals/Dependencies/Moderation/Filter.php b/globals/Dependencies/Moderation/Filter.php
new file mode 100644
index 0000000..743bb92
--- /dev/null
+++ b/globals/Dependencies/Moderation/Filter.php
@@ -0,0 +1,121 @@
+rank != 2) //dont log admins chats
diff --git a/html/register.php b/html/register.php
index bd091c0..33f4112 100644
--- a/html/register.php
+++ b/html/register.php
@@ -5,6 +5,7 @@
TODO: This needs a re-do. This is one of the first pages on this project
*/
+use Alphaland\Moderation\Filter;
use Alphaland\Users\Activation;
use Alphaland\Users\ReferralProgram;
use Alphaland\Web\WebContextManager;
@@ -55,7 +56,7 @@ else
{
$error = '
Your username must be between 3 and 20 characters long
';
}
- if(isFiltered($uname))
+ if (Filter::IsTextFiltered($uname))
{
$error = 'Username is not appropriate for Alphaland
';
}
diff --git a/html_api/moderation/v2/filtertext.php b/html_api/moderation/v2/filtertext.php
index f6ede32..5ca4780 100644
--- a/html_api/moderation/v2/filtertext.php
+++ b/html_api/moderation/v2/filtertext.php
@@ -1,5 +1,6 @@
false)));
}
-if (isFiltered($text)) {
+if (Filter::IsTextFiltered($text))
+{
logChatMessage($userid, $text, true);
if (chatFilterInfractionLimit($userid, 3, 120)) //3 infraction within 2 minutes
@@ -19,7 +21,7 @@ if (isFiltered($text)) {
die(kickUserIfInGame($userid, "'".$text."' is not appropriate on Alphaland, continued infractions will lead to a ban."));
}
- $text = filterText($text);
+ $text = Filter::FilterText($text);
//$text = "[ Content Deleted ]";
}