Skip to content
This repository has been archived by the owner on Jul 22, 2022. It is now read-only.

Commit

Permalink
Creating the Sign-In/Sign-Out/Sign-Up Links
Browse files Browse the repository at this point in the history
  • Loading branch information
sdflem committed Feb 28, 2020
1 parent 3e141f0 commit 770db83
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions app/views/layouts/application.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,16 @@

<body>

<ul>
<% if user_signed_in? %>
<li><%= link_to "Hi, #{current_user.email}", edit_user_registration_path %></li>
<li><%= link_to 'Sign Out', destroy_user_session_path, method: :delete %></li>
<% else %>
<li><%= link_to 'Sign In', new_user_session_path %></li>
<li><%= link_to 'Sign Up', new_user_registration_path %></li>
<% end %>
</ul>

<% flash.each do |key, message| %>
<p><%= message %></p>
<% end %>
Expand Down

0 comments on commit 770db83

Please sign in to comment.