Cooldowns: Fix for patreon perks not applying
if cooldown resets are trigered by a drop. The tier parameter wasn't passed from within thedrop command. We should probably move the tier fetch logic into getCooldown.
This commit is contained in:
@@ -129,7 +129,7 @@ module.exports = {
|
||||
if (await cards[cardId].userId) { i.reply({ content: "This card has already been claimed!", ephemeral: true }); return; }
|
||||
|
||||
let claimUser = await UserUtils.getUserByDiscordId(i.user.id);
|
||||
let cooldowns = await UserUtils.getCooldowns(claimUser);
|
||||
let cooldowns = await UserUtils.getCooldowns(claimUser, (await UserUtils.getPatreonPerks(interaction.client, claimUser))['tier']);
|
||||
let permissionLevel = await UserUtils.getPermissionLevel(i.member);
|
||||
if (cooldowns.remainingClaims <= 0 && cooldowns.nextClaimReset > 0 && permissionLevel < 2) {
|
||||
i.reply({
|
||||
|
||||
Reference in New Issue
Block a user