]> git.openstreetmap.org Git - rails.git/blobdiff - app/views/layouts/_header.html.erb
Simplify remaining link_to ... user_path in views
[rails.git] / app / views / layouts / _header.html.erb
index 55f37782da4fa8ce6ec8aa9c7b4572b45ae7aa5c..97be3f7b8c96b78774ed2e5fd09dc3608ee3744c 100644 (file)
@@ -9,7 +9,7 @@
   <nav class='primary'>
     <%= content_for :header %>
     <div class="btn-group">
-      <div id="edit_tab" class="btn-group <%= current_page_class(edit_path) %>">
+      <div id="edit_tab" class="btn-group">
         <%= link_to t("layouts.edit"),
                     edit_path,
                     :class => "btn btn-outline-primary geolink editlink",
@@ -27,8 +27,8 @@
           <% end %>
         </ul>
       </div>
-      <%= link_to t("layouts.history"), history_path, :class => "btn btn-outline-primary geolink flex-grow-1 current_page_class(history_path)", :id => "history_tab" %>
-      <%= link_to t("layouts.export"), export_path, :class => "btn btn-outline-primary geolink current_page_class(export_path)", :id => "export_tab" %>
+      <%= link_to t("layouts.history"), history_path, :class => "btn btn-outline-primary geolink flex-grow-1", :id => "history_tab" %>
+      <%= link_to t("layouts.export"), export_path, :class => "btn btn-outline-primary geolink", :id => "export_tab" %>
     </div>
   </nav>
   <nav class='secondary'>
@@ -96,7 +96,7 @@
             <%= t("users.show.my messages") %>
             <span class='badge count-number'><%= number_with_delimiter(current_user.new_messages.size) %></span>
           <% end %>
-          <%= link_to t("users.show.my profile"), user_path(current_user), :class => "dropdown-item" %>
+          <%= link_to t("users.show.my profile"), current_user, :class => "dropdown-item" %>
           <%= link_to t("users.show.my settings"), edit_account_path, :class => "dropdown-item" %>
           <%= link_to t("users.show.my_preferences"), preferences_path, :class => "dropdown-item" %>
           <div class="dropdown-divider"></div>