<commit_before>defmodule MicoseBackend.UserView do
  use MicoseBackend.Web, :view

  def render("index.json", %{users: users}) do
    %{data: render_many(users, MicoseBackend.UserView, "user.json")}
  end

  def render("show.json", %{user: user}) do
    %{data: render_one(user, MicoseBackend.UserView, "user.json")}
  end

  def render("user.json", %{user: user}) do
    %{id: user.id,
      pseudo: user.pseudo}
  end
end
<commit_msg>Fix user view for nullable borrower.<commit_after>defmodule MicoseBackend.UserView do
  use MicoseBackend.Web, :view

  def render("index.json", %{users: users}) do
    %{data: render_many(users, MicoseBackend.UserView, "user.json")}
  end

  def render("show.json", %{user: user}) do
    %{data: render_one(user, MicoseBackend.UserView, "user.json")}
  end

  def render("user.json", %{user: nil}) do
    nil
  end

  def render("user.json", %{user: user}) do
    %{id: user.id,
      pseudo: user.pseudo}
  end
end

{'fraction_non_alphanumeric': 0.15634837355718784, 'fraction_numerical': 0.0, 'mean_word_length': 4.021052631578947, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '6475064', 'n_tokens_mistral': 351, 'n_tokens_neox': 346, 'n_words': 86}