Fix for events without an MIC causing 500 errors for people with permission to view profiles.

This commit is contained in:
Tom Price
2015-05-29 15:20:29 +01:00
parent 86b570e3e8
commit c867ce49ef

View File

@@ -110,7 +110,7 @@
{% if event.is_rig %} {% if event.is_rig %}
<dt>Event MIC</dt> <dt>Event MIC</dt>
<dd> <dd>
{% if perms.RIGS.view_profile %} {% if event.mic and perms.RIGS.view_profile %}
<a href="{% url 'profile_detail' event.mic.pk %}" class="modal-href"> <a href="{% url 'profile_detail' event.mic.pk %}" class="modal-href">
{{ event.mic.name }} {{ event.mic.name }}
</a> </a>