I'm tired of this...
This commit is contained in:
parent
d758118272
commit
a890ee51be
4
main.cjs
4
main.cjs
@ -183,13 +183,13 @@ function getMatchingPhrase(inputString, targetCharacter) {
|
|||||||
global.clenseDegeneracy = function clenseDegeneracy(message) {
|
global.clenseDegeneracy = function clenseDegeneracy(message) {
|
||||||
function normalizeString(str) {
|
function normalizeString(str) {
|
||||||
// Define a mapping of characters to 's'
|
// Define a mapping of characters to 's'
|
||||||
const sMap = { '$': 's', '5': 's' };
|
const sMap = { '$': 's', '5': 's', 'š': 's'};
|
||||||
|
|
||||||
// Replace similar characters with 's'
|
// Replace similar characters with 's'
|
||||||
return str.split('').map(char => sMap[char] || char).join('');
|
return str.split('').map(char => sMap[char] || char).join('');
|
||||||
}
|
}
|
||||||
let checkString = normalizeString(message.content.toLowerCase());
|
let checkString = normalizeString(message.content.toLowerCase());
|
||||||
let checkArray = ["ussy", "ussies"];
|
let checkArray = ["ussy", "ussies", "uthy"];
|
||||||
function checkLoop(message, content) {
|
function checkLoop(message, content) {
|
||||||
console.log("Checking " + content + "...");
|
console.log("Checking " + content + "...");
|
||||||
for (let i = 0; i < checkArray.length; i++) {
|
for (let i = 0; i < checkArray.length; i++) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user