Skip to content

Commit

Permalink
Merge pull request #93 from multiversx/blacklist-only-for-users-with-…
Browse files Browse the repository at this point in the history
…allowance

Allow blacklist only for users with ticket allowance
  • Loading branch information
psorinionut authored Jan 27, 2025
2 parents f171bb0 + 6a48f28 commit aa43fee
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions launchpad-common/src/blacklist.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ pub trait BlacklistModule:
!blacklist_mapper.contains(&address),
"User already blacklisted"
);

require!(
!self.ticket_range_for_address(&address).is_empty(),
"User has no ticket allowance"
);

let confirmed_tickets_mapper = self.nr_confirmed_tickets(&address);
let nr_confirmed_tickets = confirmed_tickets_mapper.get();
if nr_confirmed_tickets > 0 {
Expand Down

0 comments on commit aa43fee

Please sign in to comment.