<commit_before><h1>API Users</h1>

<div class="row-fluid">
  <div class="span6">
    <%= form_tag(admin_api_users_path, :method => :get, :class => "form-search") do %>
      <div class="input-append">
        <%= text_field_tag(:search, params[:search], :class => "search-query") %>
        <button type="submit" class="btn">Search</button>
      </div>
    <% end %>
  </div>
  <div class="span6 button-actions">
    <%= link_to '<i class="icon-plus icon-white"></i> Add New API User'.html_safe, new_admin_api_user_path, :class => "btn btn-primary" %>
  </div>
</div>

<table class="table table-striped">
  <thead>
    <tr>
      <th scope="col">E-mail</th>
      <th scope="col">First Name</th>
      <th scope="col">Last Name</th>
      <th scope="col">Puprose</th>
      <th scope="col">Created</th>
      <th scope="col">API Key</th>
    </tr>
  </thead>
  <tbody>
    <% @api_users.each do |api_user| %>
      <tr>
        <td><%= link_to(api_user.email, edit_admin_api_user_path(api_user)) %></td>
        <td><%= api_user.first_name %></td>
        <td><%= api_user.last_name %></td>
        <td title="<%= api_user.use_description %>"><%= api_user.use_description.truncate(50, :separator => " ") %></td>
        <td><%= api_user.created_at %></td>
        <td><small class="api-key"><%= api_user.api_key.truncate(11) %></small></td>
      </tr>
    <% end %>
  </tbody>
</table>

<%= paginate @api_users %>
<commit_msg>Fix api users admin listing when use_description is nil.<commit_after><h1>API Users</h1>

<div class="row-fluid">
  <div class="span6">
    <%= form_tag(admin_api_users_path, :method => :get, :class => "form-search") do %>
      <div class="input-append">
        <%= text_field_tag(:search, params[:search], :class => "search-query") %>
        <button type="submit" class="btn">Search</button>
      </div>
    <% end %>
  </div>
  <div class="span6 button-actions">
    <%= link_to '<i class="icon-plus icon-white"></i> Add New API User'.html_safe, new_admin_api_user_path, :class => "btn btn-primary" %>
  </div>
</div>

<table class="table table-striped">
  <thead>
    <tr>
      <th scope="col">E-mail</th>
      <th scope="col">First Name</th>
      <th scope="col">Last Name</th>
      <th scope="col">Puprose</th>
      <th scope="col">Created</th>
      <th scope="col">API Key</th>
    </tr>
  </thead>
  <tbody>
    <% @api_users.each do |api_user| %>
      <tr>
        <td><%= link_to(api_user.email, edit_admin_api_user_path(api_user)) %></td>
        <td><%= api_user.first_name %></td>
        <td><%= api_user.last_name %></td>
        <td title="<%= api_user.use_description %>"><%= api_user.use_description.to_s.truncate(50, :separator => " ") %></td>
        <td><%= api_user.created_at %></td>
        <td><small class="api-key"><%= api_user.api_key.truncate(11) %></small></td>
      </tr>
    <% end %>
  </tbody>
</table>

<%= paginate @api_users %>

{'fraction_non_alphanumeric': 0.22038567493112948, 'fraction_numerical': 0.005509641873278237, 'mean_word_length': 3.240875912408759, 'pattern_counts': {'":': 0, '<': 131, '<?xml version=': 0, '>': 141, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4427288', 'n_tokens_mistral': 1133, 'n_tokens_neox': 1072, 'n_words': 202}