Fixed .toLowerCase bug
This commit is contained in:
parent
8fbfc024d5
commit
fb783c293e
7
bot.js
7
bot.js
|
@ -19,8 +19,8 @@ bot.addListener("error", (message) => {
|
|||
});
|
||||
|
||||
bot.addListener("pm", function(from, message) {
|
||||
from = String.toLowerCase(from);
|
||||
message = String.toLowerCase(message);
|
||||
from = from.toLowerCase();
|
||||
message = message.toLowerCase();
|
||||
|
||||
if(from === owner) {
|
||||
if( message === "quit") {
|
||||
|
@ -32,4 +32,5 @@ bot.addListener("pm", function(from, message) {
|
|||
bot.say(from, "You are not my boss!");
|
||||
console.log(from + " tried to control me!");
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue