mirror of
https://github.com/internetee/registry.git
synced 2025-05-21 19:59:38 +02:00
Fix rubocop
This commit is contained in:
parent
a4ebb24a03
commit
5ed983fd2e
4 changed files with 5 additions and 6 deletions
|
@ -7,9 +7,9 @@ class Ability
|
|||
@user = user || User.new
|
||||
@user.roles.each { |role| send(role) } if @user.roles
|
||||
|
||||
if @user.roles.nil? || @user.roles.empty?
|
||||
can :show, :dashboard
|
||||
end
|
||||
return if @user.roles || @user.roles.any?
|
||||
|
||||
can :show, :dashboard
|
||||
end
|
||||
|
||||
def user
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue