mirror of
https://github.com/fspc/BikeShed-1.git
synced 2025-02-28 16:53:23 -05:00
Update Ability to get user roles, not role
This commit is contained in:
parent
a083ed715b
commit
6f6902dd82
@ -3,7 +3,9 @@ class Ability
|
|||||||
|
|
||||||
def initialize(current_user)
|
def initialize(current_user)
|
||||||
@current_user = current_user
|
@current_user = current_user
|
||||||
self.send(current_user.role.role.to_sym)
|
current_user.roles.each do |role|
|
||||||
|
self.send(role.role.to_sym)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def admin
|
def admin
|
||||||
|
Loading…
x
Reference in New Issue
Block a user