{#

This file is part of the Sonata package.

(c) Thomas Rabaix <thomas.rabaix@sonata-project.org>

For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.

#}
{% extends sonata_block.templates.block_base %}

{% block block %}
    {% if settings.title %}
        <h3 class="sonata-media-block-media-title">{{ settings.title }}</h3>
    {% endif %}

    <div class="sonata-media-block-media-container">
        {% if media %}
            {% media media, settings.format %}
        {% else %}
            {# no media selected ... #}
        {% endif %}
    </div>
{% endblock %}

{#

This file is part of the Sonata package.

(c) Thomas Rabaix <thomas.rabaix@sonata-project.org>

For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.

#}
{% extends sonata_block.templates.block_base %}

{% block block %}
    {% if settings.title %}
        <h3 class="sonata-media-block-media-title">{{ settings.title }}</h3>
    {% endif %}

    <div class="sonata-media-block-media-container">
        {% if media and settings.format%}
            {% media media, settings.format %}
        {% else %}
            {# no media selected or format defined... #}
        {% endif %}
    </div>
{% endblock %}

Fix error if no format is defined
Fix error if no format is defined
