Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Fix Jinja templating error when generating thumbnail URLs. (#12510)
Browse files Browse the repository at this point in the history
scale is meant to be a constant string, not refer to a variable.
  • Loading branch information
clokep authored Apr 20, 2022
1 parent ecef741 commit 103f51d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions changelog.d/12510.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix a long-standing bug where the image thumbanils embedded into email notifications were broken.
2 changes: 1 addition & 1 deletion synapse/res/templates/notif.html
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
{%- elif message.msgtype == "m.notice" %}
{{ message.body_text_html }}
{%- elif message.msgtype == "m.image" and message.image_url %}
<img src="{{ message.image_url|mxc_to_http(640, 480, scale) }}" />
<img src="{{ message.image_url|mxc_to_http(640, 480, 'scale') }}" />
{%- elif message.msgtype == "m.file" %}
<span class="filename">{{ message.body_text_plain }}</span>
{%- else %}
Expand Down

0 comments on commit 103f51d

Please sign in to comment.