1
0
mirror of https://github.com/musix-org/musix-oss synced 2025-06-17 04:26:00 +00:00

3.2 fixes and improvements

This commit is contained in:
MatteZ02
2020-04-19 23:21:06 +03:00
parent 03516e4074
commit 7fc4576fb0
6 changed files with 78 additions and 37 deletions

View File

@ -16,7 +16,9 @@ module.exports = {
secret: client.config.spotify_client_secret,
});
spotify.setAccessToken(client.config.spotify_access_key);
spotify.setAccessToken(
client.global.db.guilds[msg.guild.id].spotify_access_key
);
const youtube = new YouTube(client.config.api_key);
const searchString = args.slice(1).join(" ");
@ -123,7 +125,7 @@ module.exports = {
},
function (err) {
console.log(err);
msg.channel.send(client.messages.noResults);
msg.channel.send(client.messages.noResultsSpotify);
}
);
} else if (

View File

@ -26,7 +26,7 @@ module.exports = {
)
.addField(
client.messages.settingsBlacklist,
client.messages.settingsBlacklist,
client.messages.settingsBlacklistDesc,
true
)
.addField(
@ -48,6 +48,11 @@ module.exports = {
client.messages.settingsBassDesc,
true
)
.addField(
client.messages.settingsSetKey,
client.messages.settingsSetKeyDesc,
true
)
.setFooter(footer)
.setAuthor(client.user.username, client.user.displayAvatarURL)
.setColor(client.config.embedColor);

View File

@ -1,12 +1,12 @@
module.exports = {
name: "premium",
async execute(msg, args, client) {
if (msg.member.id !== client.config.devId)
return msg.channel.send(client.messages.onlyDev);
if (!args[2])
return msg.channel.send(
`${client.messages.correctUsage} ${client.messages.premiumUsage}`
client.messages.premiumState + client.global.db.guilds[args[2]].premium
);
if (msg.member.id !== client.config.devId)
return msg.channel.send(client.messages.onlyDev);
if (client.global.db.guilds[args[2]].premium === false) {
client.global.db.guilds[args[2]].premium = true;
let message;

View File

@ -0,0 +1,6 @@
module.exports = {
name: "setkey",
async execute(msg, args, client) {
msg.channel.send(client.messages.setKeyUsage);
},
};