Edit variable name to snakeCase
This commit is contained in:
parent
dbfa8f058b
commit
e189fd63be
1 changed files with 3 additions and 3 deletions
|
@ -1,6 +1,6 @@
|
||||||
module.exports = function (text, guild) {
|
module.exports = function (text, guild) {
|
||||||
let id = "";
|
let id = "";
|
||||||
let ismention = false;
|
let isMention = false;
|
||||||
if (
|
if (
|
||||||
text.substring(0, 2) == "<@" &&
|
text.substring(0, 2) == "<@" &&
|
||||||
text.substring(text.length - 1, text.length) == ">"
|
text.substring(text.length - 1, text.length) == ">"
|
||||||
|
@ -8,13 +8,13 @@ module.exports = function (text, guild) {
|
||||||
let start = 2;
|
let start = 2;
|
||||||
if (text.substring(0, 3) == "<@!") start = 3;
|
if (text.substring(0, 3) == "<@!") start = 3;
|
||||||
id = text.substring(start, text.length - 1);
|
id = text.substring(start, text.length - 1);
|
||||||
ismention = true;
|
isMention = true;
|
||||||
} else {
|
} else {
|
||||||
if (!isNaN(text)) {
|
if (!isNaN(text)) {
|
||||||
id = text;
|
id = text;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!ismention) {
|
if (!isMention) {
|
||||||
guild.members.cache.each(function (guildMember, guildMemberID) {
|
guild.members.cache.each(function (guildMember, guildMemberID) {
|
||||||
let compare = text.toLowerCase();
|
let compare = text.toLowerCase();
|
||||||
if (guildMember.user.username.toLowerCase().includes(compare)) {
|
if (guildMember.user.username.toLowerCase().includes(compare)) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue