<commit_before>{% block extends %}
{{ "{% extends '::base.html.twig' %}" }}
{% endblock extends %}

{% block body %}
{{ "{% block body %}" }}
    <h1>{{ entity }}</h1>

    <table class="record_properties">
        <tbody>
        {%- for field, metadata in fields %}

            <tr>
                <th>{{ field|capitalize }}</th>

            {%- if metadata.type in ['date', 'datetime'] %}

                <td>{{ '{{ ' ~ entity_singularized ~ '.' ~ field|replace({'_': ''}) ~ '|date(\'Y-m-d H:i:s\') }}' }}</td>

            {%- else %}

                <td>{{ '{{ ' ~ entity_singularized ~ '.' ~ field|replace({'_': ''}) ~ ' }}' }}</td>

            {%- endif %}

            </tr>

        {%- endfor %}

        </tbody><commit_msg>Make the "show" template check datetime fields before displaying them (as the "index" template already does)<commit_after>{% block extends %}
{{ "{% extends '::base.html.twig' %}" }}
{% endblock extends %}

{% block body %}
{{ "{% block body %}" }}
    <h1>{{ entity }}</h1>

    <table class="record_properties">
        <tbody>
        {%- for field, metadata in fields %}

            <tr>
                <th>{{ field|capitalize }}</th>

            {%- if metadata.type in ['date', 'datetime'] %}

                <td>{{ '{% if ' ~ entity_singularized ~ '.' ~ field|replace({'_': ''}) ~ ' %}{{ ' ~ entity_singularized ~ '.' ~ field|replace({'_': ''}) ~ '|date(\'Y-m-d H:i:s\') }}{% endif %}' }}</td>

            {%- else %}

                <td>{{ '{{ ' ~ entity_singularized ~ '.' ~ field|replace({'_': ''}) ~ ' }}' }}</td>

            {%- endif %}

            </tr>

        {%- endfor %}

        </tbody>
{'fraction_non_alphanumeric': 0.24683162341581172, 'fraction_numerical': 0.0024140012070006035, 'mean_word_length': 1.9449378330373002, 'pattern_counts': {'":': 0, '<': 29, '<?xml version=': 0, '>': 29, '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': '2883873', 'n_tokens_mistral': 590, 'n_tokens_neox': 513, 'n_words': 110}