-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ルーティングの修正。ログアウトが機能しなかったので、link_toからbutton_toに修正。
- Loading branch information
Showing
4 changed files
with
19 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,7 @@ | ||
<h1>Home#index</h1> | ||
<p>Find me in app/views/home/index.html.erb</p> | ||
|
||
<% if user_signed_in? %> | ||
<h2>Welcome, <%= current_user.email %></h2> | ||
<%= link_to 'Logout', destroy_user_session_path, method: :delete %> | ||
<h2>ログイン中</h2> | ||
<%= button_to 'Logout', destroy_user_session_path, method: :delete %> | ||
<% else %> | ||
<h2>未ログイン</h2> | ||
<%= link_to 'Login', new_user_session_path %> | ||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters