Strip the trailing comma on the first line of an address block.

This commit is contained in:
Rebecca Law
2020-01-08 11:22:14 +00:00
parent f7b3f9b06a
commit 9d1f92a752
5 changed files with 65 additions and 40 deletions

View File

@@ -19,7 +19,7 @@
{% if item.status in ('pending-virus-check', 'virus-scan-failed') %}
<span class="file-list-filename loading-indicator">Checking</span>
{% else %}
<a class="file-list-filename" href="{{ url_for('.view_notification', service_id=current_service.id, notification_id=item.id) }}">{{ item.to.splitlines()[0].lstrip().rstrip(' ,') }}</a>
<a class="file-list-filename" href="{{ url_for('.view_notification', service_id=current_service.id, notification_id=item.id) }}">{{ item.to.splitlines()[0].lstrip().rstrip(' ,') if item.to else '' }}</a>
{% endif %}
<p class="file-list-hint">
{{ item.preview_of_content }}