Skip to content
Snippets Groups Projects
Commit 76daec43 authored by Mateus Rambo Strey's avatar Mateus Rambo Strey
Browse files

Merge branch 'master' of gitlab.c3sl.ufpr.br:portalmec/portalmec

parents db44f2b4 620bad84
No related branches found
No related tags found
No related merge requests found
......@@ -76,7 +76,9 @@ class Management::UsersController < ManagementController
@curators = Array.new
@users = User.includes(:roles).all
@users.all.each do |user|
@curators << user if user.roles[0].name == "curator"
if !user.roles[0].nil?
@curators << user if user.roles[0].name == "curator" || []
end
end
end
......@@ -84,7 +86,9 @@ class Management::UsersController < ManagementController
@admins = Array.new
@users = User.includes(:roles).all
@users.all.each do |user|
@admins << user if user.roles[0].name == "admin"
if !user.roles[0].nil?
@admins << user if user.roles[0].name == "admin" || []
end
end
end
......
......@@ -25,4 +25,8 @@
<li><%= link_to "Denúncias", management_complaints_path, class: 'ls-ico-bullhorn' %>
<li>
</ul>
<li> <%= link_to "Voltar ao Portal", root_path %> </li>
</nav>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment