JaBa/commands/Economy/setbio.js

30 lines
734 B
JavaScript
Raw Normal View History

const Command = require("../../base/Command");
2022-01-04 02:18:28 +05:00
class Setbio extends Command {
constructor(client) {
super(client, {
name: "setbio",
dirname: __dirname,
enabled: true,
guildOnly: false,
aliases: ["biography", "setdesc", "sb"],
memberPermissions: [],
botPermissions: ["SEND_MESSAGES", "EMBED_LINKS"],
nsfw: false,
ownerOnly: false,
cooldown: 1000
});
}
async run(message, args, data) {
const newBio = args.join(" ");
if (!newBio) return message.error("economy/setbio:MISSING");
if (newBio.length > 100) return message.error("economy/setbio:MAX_CHARACT");
data.userData.bio = newBio;
message.success("economy/setbio:SUCCESS");
await data.userData.save();
}
2022-01-13 00:26:23 +05:00
}
2022-01-04 02:18:28 +05:00
module.exports = Setbio;