User badge reappear even after being revoked by the admin?


(Mohit Gupta) #1

After revoking a user’s badges from admin panel the badges are reassigned to that user. Is their any way to stop reassigning of that badge to user when it has been revoked by the admin?


(Kane York) #2

Which badges are you trying to revoke? It won’t work too well if it’s an automatic badge…


(Mohit Gupta) #3

@riking Is their any any property that I can set to prevent it from happening. I am trying it for badges that can be granted multiple times.


(Stephen) #4

Badges aren’t event-driven though, right? They’re awarded by scheduled queries. You can see the scheduled job at /sidekiq/scheduler

So if the conditions to award that badge remain true, whether once or multiple times, then revocation will only apply until the query runs again. If you revoke the first instance of a badge which can be awarded multiple times then every instance of the condition which awards the badge will continue to trigger badges to be awarded.

Which badge are you trying to revoke and why?


(Mohit Gupta) #5

@steve_pd I was thinking of developing a scenario where a user can get rewarded for a badge that he earns. The process will be very simple to understand in case of multiple badges if I can revoke the badge that it has been cashed in.
I was thinking of having a column in the badges table that indicates the badge has been revoked by the user and prevent it from regranting.


(Sam Saffron) #6

We support manually revoked badges just don’t specify a badge query, or have your badge query somehow bypass the badges you revoke if there is some sort of record in the db that denotes why you did it.