<commit_before>{% if isJournalManager is defined %}
    <div class="panel panel-default">
        <div class="panel-heading">
            <a href="{{ url('ojs_block_new',{object: journal.id, type:'journal'}) }}">
                <span class="panel-title">
                    <i class="fa fa-plus"></i> {{ "new.block"|trans }}
                </span>
            </a></div>
    </div>
{% endif %}
{% for block in blocks %}
    <div class="panel panel-{{ block.color|default("default") }}">
        <div class="panel-heading">
            <span class="panel-title">{{ block.title|trans }}</span>
            {% if isJournalManager() %}
                <input type="number"  min="1" max="10000" class="col-xs-2 pull-right no-pad block_order_updater"
                       data-block-id="{{ block.id }}" value="{{ block.blockOrder|default(0) }}">
                <a href="{{ url('ojs_block_new',{object: journal.id, type:'journal',id:block.id}) }}" title="Edit Block"
                   class="pull-right"><i class="fa fa-pencil "></i></a>
                <a href="{{ url('ojs_block_delete',{object: journal.id, type:'journal',block:block.id}) }}"
                   title="Delete Block" class="pull-right"><i class="fa fa-trash "></i></a>
                {% endif %}
        </div>
        {% if block.type=='html' %}
            {{ block.content|raw }}
        {% elseif block.type=='link' %}
            <ul class="list-group">
                {% for link in block.links %}
                    <li class="list-group-item">
                        <a href="{{ link.url }}" target="_blank">{{ link.text }}</a>
                        {% if isJournalManager() %}
                            <input type="number" min="1" max="10000"  name="blocklink[{{ link.id }}]" data-link-id="{{ link.id }}"
                                   value="{{ link.linkOrder|default(0) }}"
                                   class="col-xs-2 no-pad pull-right blocklink_order_updater"/>
                            <a href="{{ url('ojs_block_link_new',{block: block.id, id:link.id}) }}" title="Edit Link"
                               class="pull-right"><i class="fa fa-pencil "></i></a>
                            <a href="{{ url('ojs_block_link_delete',{object: journal.id, type:'journal',block_link:link.id}) }}"
                               title="Delete Link" class="pull-right"><i class="fa fa-trash "></i></a>
                            {% endif %}

                    </li>
                {% endfor %}
                {% if isJournalManager() %}
                    <li class="list-group-item"><a
                            href="{{ url('ojs_block_link_new',{block: block.id}) }}"><i
                                class="fa fa-plus"></i> <strong>{{ "Add Link"|trans }}</strong></a>
                    </li>
                {% endif %}
            </ul>
        {% endif %}
    </div>
{% endfor %}
<commit_msg>isJournalManager is defined. to be or not to be<commit_after>{% if isJournalManager is defined %}
    <div class="panel panel-default">
        <div class="panel-heading">
            <a href="{{ url('ojs_block_new',{object: journal.id, type:'journal'}) }}">
                <span class="panel-title">
                    <i class="fa fa-plus"></i> {{ "new.block"|trans }}
                </span>
            </a></div>
    </div>
{% endif %}
{% for block in blocks %}
    <div class="panel panel-{{ block.color|default("default") }}">
        <div class="panel-heading">
            <span class="panel-title">{{ block.title|trans }}</span>
            {% if isJournalManager is defined %}
                <input type="number"  min="1" max="10000" class="col-xs-2 pull-right no-pad block_order_updater"
                       data-block-id="{{ block.id }}" value="{{ block.blockOrder|default(0) }}">
                <a href="{{ url('ojs_block_new',{object: journal.id, type:'journal',id:block.id}) }}" title="Edit Block"
                   class="pull-right"><i class="fa fa-pencil "></i></a>
                <a href="{{ url('ojs_block_delete',{object: journal.id, type:'journal',block:block.id}) }}"
                   title="Delete Block" class="pull-right"><i class="fa fa-trash "></i></a>
                {% endif %}
        </div>
        {% if block.type=='html' %}
            {{ block.content|raw }}
        {% elseif block.type=='link' %}
            <ul class="list-group">
                {% for link in block.links %}
                    <li class="list-group-item">
                        <a href="{{ link.url }}" target="_blank">{{ link.text }}</a>
                        {% if isJournalManager is defined %}
                            <input type="number" min="1" max="10000"  name="blocklink[{{ link.id }}]" data-link-id="{{ link.id }}"
                                   value="{{ link.linkOrder|default(0) }}"
                                   class="col-xs-2 no-pad pull-right blocklink_order_updater"/>
                            <a href="{{ url('ojs_block_link_new',{block: block.id, id:link.id}) }}" title="Edit Link"
                               class="pull-right"><i class="fa fa-pencil "></i></a>
                            <a href="{{ url('ojs_block_link_delete',{object: journal.id, type:'journal',block_link:link.id}) }}"
                               title="Delete Link" class="pull-right"><i class="fa fa-trash "></i></a>
                            {% endif %}

                    </li>
                {% endfor %}
                {% if isJournalManager is defined %}
                    <li class="list-group-item"><a
                            href="{{ url('ojs_block_link_new',{block: block.id}) }}"><i
                                class="fa fa-plus"></i> <strong>{{ "Add Link"|trans }}</strong></a>
                    </li>
                {% endif %}
            </ul>
        {% endif %}
    </div>
{% endfor %}

{'fraction_non_alphanumeric': 0.18691429545067303, 'fraction_numerical': 0.005452376895552905, 'mean_word_length': 1.6322869955156951, 'pattern_counts': {'":': 0, '<': 99, '<?xml version=': 0, '>': 99, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3874335', 'n_tokens_mistral': 1767, 'n_tokens_neox': 1628, 'n_words': 328}