Add async for await

This commit is contained in:
Jordan 2022-10-10 11:43:16 -05:00 committed by GitHub
parent 75bfe9e5fa
commit c8415c404d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -33,7 +33,7 @@ module.exports = async (client, interaction, args) => {
inline: true inline: true
} }
] ]
}, member).then(function () { }, member).then(async function () {
member.ban({ reason: reason }) member.ban({ reason: reason })
client.succNormal({ client.succNormal({
text: "The specified user has been successfully banned and successfully received a notification!", text: "The specified user has been successfully banned and successfully received a notification!",
@ -61,7 +61,7 @@ module.exports = async (client, interaction, args) => {
expires, expires,
}).save(); }).save();
}).catch(function () { }).catch(async function () {
member.ban({ reason: reason }) member.ban({ reason: reason })
client.succNormal({ client.succNormal({
text: "The given user has been successfully banned, but has not received a notification!", text: "The given user has been successfully banned, but has not received a notification!",
@ -79,4 +79,4 @@ module.exports = async (client, interaction, args) => {
}); });
} }