Use an event's category image for OpenGraph image when available

This commit is contained in:
Michael Hall 2018-04-02 22:49:12 -04:00
parent 0a1832d026
commit 2840c3445d

View file

@ -8,7 +8,11 @@
<meta property="og:type" content="website" />
<meta property="og:title" content="{{event.name}}" />
<meta property="og:description" content="{{event.summary}}" />
{% if event.team.category %}
<meta property="og:image" content="{{event.team.category.img_url}}" />
{% else %}
<meta property="og:image" content="https://gettogether.community{% static 'img/team_placeholder.png' %}" />
{% endif %}
{% endblock %}
{% block styles %}