Преглед на файлове

Fix Jinja templating error when generating thumbnail URLs. (#12510)

scale is meant to be a constant string, not refer to a variable.
Patrick Cloke преди 2 години
родител
ревизия
103f51d867
променени са 2 файла, в които са добавени 2 реда и са изтрити 1 реда
  1. 1 0
      changelog.d/12510.bugfix
  2. 1 1
      synapse/res/templates/notif.html

+ 1 - 0
changelog.d/12510.bugfix

@@ -0,0 +1 @@
+Fix a long-standing bug where the image thumbanils embedded into email notifications were broken.

+ 1 - 1
synapse/res/templates/notif.html

@@ -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 %}