mirror of
https://github.com/musix-org/musix-oss
synced 2025-06-16 18:56:00 +00:00
new event handling
This commit is contained in:
@ -42,6 +42,14 @@ module.exports = {
|
||||
var video = await youtube.getVideoByID(videos[0].id);
|
||||
} catch (err) {
|
||||
console.error(err);
|
||||
if (err.code === 403) {
|
||||
if (client.config.api_key === client.config.api_key2) {
|
||||
client.config.api_key = client.config.api_key3;
|
||||
} else {
|
||||
client.config.api_key = client.config.api_key2;
|
||||
}
|
||||
return msg.channel.send(client.messages.quotaReached);
|
||||
}
|
||||
return msg.channel.send(client.messages.noResults);
|
||||
}
|
||||
}
|
||||
|
13
commands/savedb.js
Normal file
13
commands/savedb.js
Normal file
@ -0,0 +1,13 @@
|
||||
module.exports = {
|
||||
name: 'savedb',
|
||||
alias: 'save',
|
||||
usage: '',
|
||||
description: 'save the database',
|
||||
onlyDev: true,
|
||||
permission: 'dev',
|
||||
category: 'util',
|
||||
async execute(msg, args, client, Discord, prefix, command) {
|
||||
client.funcs.saveDB(client);
|
||||
msg.channel.send(client.messages.dbSaved);
|
||||
}
|
||||
};
|
Reference in New Issue
Block a user