Skip to content

Commit

Permalink
Adds nav link to admin area for admin users
Browse files Browse the repository at this point in the history
  • Loading branch information
matt-bernhardt committed Aug 7, 2024
1 parent fccf8fb commit 6208d88
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions app/views/layouts/_site_nav.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
<div class="wrap-bar">
<nav class="local-nav" aria-label="Main menu">
<%= nav_link_to("Home", root_path) %>
<% if current_user.admin? %>
<%= link_to('Admin', admin_root_path, class: 'nav-item') %>
<% end %>
</nav>
<nav class="nav-user" aria-label="User menu">
<% if user_signed_in? %>
Expand Down

0 comments on commit 6208d88

Please sign in to comment.