Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!-- Check if the current user ID matches the users ID of the profile page -->
- <% if current_user.id == @user.id %>
- <%= button_to "Edit Profile", "#{user_path}/edit", method: :get %>
- <%= button_to "Delete Profile", @user, method: :delete, data: {confirm: "Are you sure?"} %>
- <% end %>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement