[TWIG][Attachments] Don't throw event with mimetype in its name

This commit is contained in:
Diogo Peralta Cordeiro 2021-08-18 22:08:22 +01:00 committed by Hugo Sales
parent bc1fb007aa
commit e4b2821657
No known key found for this signature in database
GPG Key ID: 7D0C7EAFC9D835A0

View File

@ -1,5 +1,5 @@
{% set handled = false %}
{% for block in handle_event('ViewAttachment' ~ attachment.getMimetypeMajor() | capitalize , {'attachment': attachment, 'note': note}) %}
{% for block in handle_event('ViewAttachment', {'attachment': attachment, 'note': note}) %}
{% set handled = true %}
{{ block | raw }}
{% endfor %}