From f1067c9783106ae27cf3ed8afe317cc0725f06ed Mon Sep 17 00:00:00 2001 From: Julian Pufler Date: Mon, 6 Jul 2020 08:14:44 +0200 Subject: [PATCH] tested and fixed --- examples/discord-bot/index.ws | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/discord-bot/index.ws b/examples/discord-bot/index.ws index 736bec3..992d5f1 100644 --- a/examples/discord-bot/index.ws +++ b/examples/discord-bot/index.ws @@ -1,17 +1,17 @@ FIX OIDA Discord = require('discord.js'); -FIX OIDA client = new Discord(); +FIX OIDA client = new Discord.Client(); client.on('ready', () => { I MAN JA NUR('bot has started'); client.user.setActivity(`Watching ${client.guilds.cache.size} servers`); }); -client.on('message', OWIZAHRA () => { +client.on('message', OWIZAHRA (message) => { WOS WÜSTN(message.author.bot) DRAH DI HAM; WOS WÜSTN(!message.content.startsWith(process.env.PREFIX)) DRAH DI HAM; - FIX OIDA args = message.content.slice(process.env.PREFIX).trim().split(/ +/g); + FIX OIDA args = message.content.replace(process.env.PREFIX, '').trim().split(/ +/g); FIX OIDA command = args.shift().toLowerCase(); WOS IS MIT DIR(command) {