mirror of
https://github.com/JonnyBro/JaBa.git
synced 2024-11-22 05:04:58 +05:00
Фиксы
This commit is contained in:
parent
46a0911f1c
commit
b3596dd64f
3 changed files with 5 additions and 3 deletions
|
@ -97,6 +97,7 @@ userSchema.method("genApiToken", async function() {
|
|||
userSchema.method("getAchievements", async function() {
|
||||
const canvas = Canvas.createCanvas(1800, 250),
|
||||
ctx = canvas.getContext("2d");
|
||||
|
||||
const images = [
|
||||
await Canvas.loadImage(`./assets/img/achievements/achievement${this.achievements.work.achieved ? "_colored" : ""}1.png`),
|
||||
await Canvas.loadImage(`./assets/img/achievements/achievement${this.achievements.firstCommand.achieved ? "_colored" : ""}2.png`),
|
||||
|
|
|
@ -85,9 +85,9 @@ class Profile extends Command {
|
|||
const buffer = userData.getAchievements();
|
||||
message.channel.send({
|
||||
embeds: [profileEmbed],
|
||||
files: [{
|
||||
attachment: buffer
|
||||
}]
|
||||
// files: [{
|
||||
// attachment: buffer
|
||||
// }]
|
||||
}); // Send the embed in the current channel
|
||||
}
|
||||
};
|
||||
|
|
|
@ -20,6 +20,7 @@ class Staff extends Command {
|
|||
async run(message, args, data) {
|
||||
await message.guild.members.fetch();
|
||||
const administrators = message.guild.members.cache.filter((m) => m.permissions.has(Discord.Permissions.FLAGS.ADMINISTRATOR) && !m.user.bot);
|
||||
console.log(administrators[0])
|
||||
const moderators = message.guild.members.cache.filter((m) => !administrators.has(m.id) && m.permissions.has(Discord.Permissions.FLAGS.MANAGE_MESSAGES) && !m.user.bot);
|
||||
const embed = new Discord.MessageEmbed()
|
||||
.setAuthor({
|
||||
|
|
Loading…
Reference in a new issue