1
0
mirror of https://github.com/musix-org/musix-oss synced 2024-11-10 05:10:17 +00:00

Update index.js

This commit is contained in:
MatteZ02 2019-07-30 16:34:58 +03:00
parent 91098e2973
commit 493df7e240

View File

@ -16,20 +16,6 @@ client.on('message', async msg => {
if (msg.content.toUpperCase().startsWith(`MUSIX`)) { if (msg.content.toUpperCase().startsWith(`MUSIX`)) {
msg.channel.send('-help to see my commands.') msg.channel.send('-help to see my commands.')
} }
if (msg.content.startsWith('>')) {
if (msg.author.id === '360363051792203779' || msg.author.id === '384002606621655040') {
if (msg.content === '>devstop') {
serverQueue.songs = [];
serverQueue.connection.dispatcher.end('Stop');
}
if (msg.content.startsWith('>eval')) {
if (msg.content.includes('process.env.BOT_TOKEN') || msg.content.includes('API_KEY')) return msg.channel.send(':x: OH HELL NO IM NOT GIVING YOU THAT! :x:')
const args = msg.content.slice(6)
msg.channel.send(eval(args));
}
return
} else return msg.channel.send(':x: Developement commands are not avaiable for public usage!');
}
if (msg.content.startsWith(`${PREFIX}`)) { if (msg.content.startsWith(`${PREFIX}`)) {
var guildms = client.guilds.find(x => x.name === 'Musix Support') var guildms = client.guilds.find(x => x.name === 'Musix Support')
var channelms = guildms.channels.find(x => x.name === 'log') var channelms = guildms.channels.find(x => x.name === 'log')
@ -335,6 +321,20 @@ ${serverQueue.songs.map(song => `**-** ${song.title}`).join("\n")}
msg.channel.send(':x: Unknown command! Type -help for the list of commands!') msg.channel.send(':x: Unknown command! Type -help for the list of commands!')
return; return;
} }
if (msg.content.startsWith('>')) {
if (msg.author.id === '360363051792203779' || msg.author.id === '384002606621655040') {
if (msg.content === '>devstop') {
serverQueue.songs = [];
serverQueue.connection.dispatcher.end('Stop');
}
if (msg.content.startsWith('>eval')) {
if (msg.content.includes('BOT_TOKEN') || msg.content.includes('API_KEY')) return msg.channel.send(':x: OH HELL NO IM NOT GIVING YOU THAT! :x:')
const args = msg.content.slice(6)
msg.channel.send(eval(args));
}
return
} else return msg.channel.send(':x: Developement commands are not avaiable for public usage!');
}
}); });
async function handleVideo(video, msg, voiceChannel, playlist = false) { async function handleVideo(video, msg, voiceChannel, playlist = false) {