<commit_before>{% load staticfiles %}
{% load thumbnail %}

<li class="search-results-item search-results-{{ object.css_class }}-item{% if not object.show_active %} inactive{% endif %}">

  {% thumbnail object.primary_image "90x90" crop="center" as im %}
    <a href="{{ object.get_absolute_url }}" class="search-image-thumbnail">
      <img src="{{ im.url }}" width="{{ im.width }}" height="{{ im.height }}"/>
    </a>
  {% empty %}
    <a href="{{ object.get_absolute_url }}" class="search-image-thumbnail">
      <img src="{% static 'images/person-90x90.jpg' %}" />
    </a>
  {% endthumbnail %}

  <section class="search-result-body">
    <h3><a href="{{ object.get_absolute_url }}">{{ object.name }}</a></h3>

    {% with pos_set=object.position_set.all.currently_active %}
    <p>

      {% for position in pos_set|slice:":4" %}
        <strong>{{ position.title.name }}</strong> of {{ position.organisation.name }};
      {% empty %}
        No currently active positions found.
      {% endfor %}

      {% with remaining=pos_set.count|add:'-4' %}
        {% if remaining > 0 %}
          and {{ remaining }} more&hellip;
        {% endif %}
      {% endwith %}

    </p><commit_msg>[NG] Don't show organization name unless there is one<commit_after>{% load staticfiles %}
{% load thumbnail %}

<li class="search-results-item search-results-{{ object.css_class }}-item{% if not object.show_active %} inactive{% endif %}">

  {% thumbnail object.primary_image "90x90" crop="center" as im %}
    <a href="{{ object.get_absolute_url }}" class="search-image-thumbnail">
      <img src="{{ im.url }}" width="{{ im.width }}" height="{{ im.height }}"/>
    </a>
  {% empty %}
    <a href="{{ object.get_absolute_url }}" class="search-image-thumbnail">
      <img src="{% static 'images/person-90x90.jpg' %}" />
    </a>
  {% endthumbnail %}

  <section class="search-result-body">
    <h3><a href="{{ object.get_absolute_url }}">{{ object.name }}</a></h3>

    {% with pos_set=object.position_set.all.currently_active %}
    <p>

      {% for position in pos_set|slice:":4" %}
        <strong>{{ position.title.name }}</strong>
        {% if position.organisation.name %}
          of {{ position.organisation.name }};
        {% endif %}
      {% empty %}
        No currently active positions found.
      {% endfor %}

      {% with remaining=pos_set.count|add:'-4' %}
        {% if remaining > 0 %}
          and {{ remaining }} more&hellip;
        {% endif %}
      {% endwith %}

    </p>
{'fraction_non_alphanumeric': 0.19751602564102563, 'fraction_numerical': 0.010416666666666666, 'mean_word_length': 2.9634920634920636, 'pattern_counts': {'":': 2, '<': 35, '<?xml version=': 0, '>': 37, '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': '5210511', 'n_tokens_mistral': 875, 'n_tokens_neox': 775, 'n_words': 172}