indexOf to charAt

This commit is contained in:
realies 2017-10-05 20:12:26 +03:00
parent 960a6d42e1
commit 9a348e3eeb

View File

@ -184,7 +184,7 @@ $(function() {
input.val("");
resetInputHeight(input.get(0));
if (text.indexOf("/") === 0) {
if (text.charAt(0) === "/") {
const args = text.substr(1).split(" ");
const cmd = args.shift().toLowerCase();
if (typeof utils.inputCommands[cmd] === "function" && utils.inputCommands[cmd](args)) {