This commit is contained in:
MatteZ02 committed 2020-04-20 19:56:23 +03:00
1 parent 2d55a3a8da
commit a6e3e8b0de
71 files changed
+158 -164

No files matched your search

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
+11 -3
View File
@@ -1,6 +1,7 @@
const YouTube = require("simple-youtube-api");
const search = require("yt-search");
const SpotifyApi = require("spotify-web-api-node");
const { globaldb } = require("../../index.js");
module.exports = {
name: "play",
@@ -16,9 +17,16 @@ module.exports = {
secret: client.config.spotify_client_secret,
});
spotify.setAccessToken(
client.global.db.guilds[msg.guild.id].spotify_access_key
);
const dbdata = await globaldb
.collection("guilds")
.doc(msg.guild.id)
.get()
.catch((err) => {
console.log("Error getting document", err);
return "error";
});
const accessKey = dbdata.data();
spotify.setAccessToken(accessKey);
const youtube = new YouTube(client.config.api_key);
const searchString = args.slice(1).join(" ");
@@ -1,7 +1,7 @@
module.exports = {
name: 'queue',
alias: 'q',
usage: '<page(opt)>',
usage: '',
description: 'See the queue.',
onlyDev: false,
permission: 'none',
@@ -25,4 +25,4 @@ module.exports = {
.setColor(client.config.embedColor)
return msg.channel.send(embed);
}
};
};
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.