Merge pull request #6 from JordanC28/patch-1

Add async for await
This commit is contained in:
CorwinDev 2022-10-12 11:15:28 +02:00 committed by GitHub
commit 1260df8298
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
}
]
}, member).then(function () {
}, member).then(async function () {
member.ban({ reason: reason })
client.succNormal({
text: "The specified user has been successfully banned and successfully received a notification!",
@ -61,7 +61,7 @@ module.exports = async (client, interaction, args) => {
expires,
}).save();
}).catch(function () {
}).catch(async function () {
member.ban({ reason: reason })
client.succNormal({
text: "The given user has been successfully banned, but has not received a notification!",
@ -79,4 +79,4 @@ module.exports = async (client, interaction, args) => {
});
}