🥅 fromUser does not exist
This commit is contained in:
parent
81c78aed7f
commit
b5b84b4862
1 changed files with 11 additions and 0 deletions
|
@ -56,6 +56,17 @@ module.exports = async (interaction) => {
|
|||
return interaction.editReply({ embeds: [embed], ephemeral: true });
|
||||
}
|
||||
|
||||
if (!fromUser) {
|
||||
const embed = {
|
||||
title: 'Transfer',
|
||||
description: 'That user has no credits, I can not transfer credits from the user',
|
||||
color: config.colors.error,
|
||||
timestamp: new Date(),
|
||||
footer: { iconURL: config.footer.icon, text: config.footer.text },
|
||||
};
|
||||
return interaction.editReply({ embeds: [embed], ephemeral: true });
|
||||
}
|
||||
|
||||
fromUser.balance -= amount;
|
||||
toUser.balance += amount;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue