<% if current_user && current_user.admin? %>

  <!-- Flash message when successfully updating/destroying a user -->
  <%= render 'flash_message' %>
  <!-- End of flash message -->

<h1>All clients</h1>

<table class="table table-striped">
  <thead>
    <tr>
      <th>Name</th>
      <th>Email</th>
      <th colspan="3"></th>
    </tr>
  </thead>

<% @users.each do |user| %>
  <tr>
    <td><%= link_to "#{user.name.capitalize}", user %></td>
    <td><%= user.email %></td>
    <td><%= link_to 'Edit', edit_user_path(user) %></td>
    <td><%= link_to 'Destroy', user, method: :delete,
                                     data: { confirm: 'Are you sure?'} %></td>
  </tr>
<% end %>
</table>

<% end %>
<% if current_user && current_user.admin? %>

  <!-- Flash message when successfully updating/destroying a user -->
  <%= render 'flash_message' %>
  <!-- End of flash message -->

<h1>All clients</h1>

<table class="table table-striped">
  <thead>
    <tr>
      <th>Name</th>
      <th>Email</th>
      <th colspan="3"></th>
    </tr>
  </thead>

<% @users.each do |user| %>
  <tr>
    <td><%= link_to "#{user.name.capitalize}", user %></td>
    <td><%= user.email %></td>
    <td><%= link_to 'Edit', edit_user_path(user) %></td>
    <td><%= link_to 'Delete', user, method: :delete,
                                     data: { confirm: 'Are you sure?'} %></td>
  </tr>
<% end %>
</table>

<% end %>
Change user destroy link text to user delete
Change user destroy link text to user delete
