fixed routes, fixed become/revert

This commit is contained in:
jomo
2014-05-01 20:56:03 +02:00
parent c2b9b1fdd7
commit c85364fdd1
4 changed files with 57 additions and 46 deletions

View File

@@ -6,9 +6,9 @@
<% end %>
<div class="profile-action" >
<% if !session[:original_user_id] && admin? %>
<%= link_to "become this user", become_user_path(@user), :class => "btn blue" %>
<%= link_to "become this user", become_path(user: @user), :class => "btn blue" %>
<% elsif session[:original_user_id] %>
<%= link_to "revert", unbecome_users_path, :class => "btn blue" %>
<%= link_to "revert", revert_path, :class => "btn blue" %>
<% end %>
</div>
<div class="clear"></div>