<h1>Welcome to GOV.UK</h1>

<div class="well">
  <h2>Your account</h2>
  <ul>
    <li><%= link_to "Change your passphrase", edit_user_path %></li>
    <li><%= link_to "Sign out", destroy_user_session_path, :method => :delete %></li>
  </ul>

  <% if current_user.is_admin? %>
    <h2>Admin tasks</h2>
    <ul>
      <li><%= link_to "Administer users", admin_users_path %></li>
      <li><%= link_to "Administer applications", admin_applications_path %></li>
    </ul>
  <% end %>

  <h2>Your Applications</h2>
  <ul>
    <% if @applications_and_permissions.any? %>
      <% @applications_and_permissions.each do |application, permission| %>
        <li>
          <h3>
            <%= link_to_if application.home_uri, application.name, application.home_uri %>
          </h3>

          <% if application.description.present? %>
            <%= simple_format application.description %>
          <% end %>

           <p>
            <% if permission.permissions.any? %>
              Roles: <em><%= permission.permissions.map(&:humanize).to_sentence %></em>
            <% end %>
          </p>
        </li>
      <% end %>
    <% else %>
      <li>You aren't yet assigned to any applications.</li>
    <% end %>
  </ul>
</div>

<h1>Welcome to GOV.UK</h1>

<div class="well">
  <h2>Your account</h2>
  <ul>
    <li><%= link_to "Change your passphrase", edit_user_path %></li>
    <li><%= link_to "Sign out", destroy_user_session_path %></li>
  </ul>

  <% if current_user.is_admin? %>
    <h2>Admin tasks</h2>
    <ul>
      <li><%= link_to "Administer users", admin_users_path %></li>
      <li><%= link_to "Administer applications", admin_applications_path %></li>
    </ul>
  <% end %>

  <h2>Your Applications</h2>
  <ul>
    <% if @applications_and_permissions.any? %>
      <% @applications_and_permissions.each do |application, permission| %>
        <li>
          <h3>
            <%= link_to_if application.home_uri, application.name, application.home_uri %>
          </h3>

          <% if application.description.present? %>
            <%= simple_format application.description %>
          <% end %>

           <p>
            <% if permission.permissions.any? %>
              Roles: <em><%= permission.permissions.map(&:humanize).to_sentence %></em>
            <% end %>
          </p>
        </li>
      <% end %>
    <% else %>
      <li>You aren't yet assigned to any applications.</li>
    <% end %>
  </ul>
</div>

Fix broken sign out link
Fix broken sign out link

This was trying to use the DELETE route that is no longer
supported by Devise.
