votes: allow Members to vote.
* Allow Member-level users to vote. * Don't allow Banned or Restricted users to create favorites any more. Banned and Restricted users aren't allowed to upvote or favorite any more to prevent sockpuppet accounts from upvoting even after they're banned.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
class FavoritePolicy < ApplicationPolicy
|
||||
def create?
|
||||
!user.is_anonymous?
|
||||
unbanned? && user.is_member?
|
||||
end
|
||||
|
||||
def destroy?
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
class PostVotePolicy < ApplicationPolicy
|
||||
def create?
|
||||
unbanned? && user.is_gold?
|
||||
unbanned? && user.is_member?
|
||||
end
|
||||
|
||||
def destroy?
|
||||
|
||||
Reference in New Issue
Block a user