Skip to content
This repository was archived by the owner on Feb 6, 2022. It is now read-only.

Commit d8d7ca2

Browse files
committed
bug #137 [Debug] Fix #122 messagePart.charset not defined (SamMcSam)
This PR was merged into the 2.3-dev branch. Discussion ---------- [Debug] Fix #122 messagePart.charset not defined Fix for the error #122 `` Method "charset" for object "Swift_Attachment" does not exist in @swiftmailer\Collector\swiftmailer.html.twig at line 170 `` that prevented the debug panel from opening when attaching files to mails. It was already done once (#37) but came back with the new design. Commits ------- 533927b [Debug] Fix #122 messagePart.charset not defined
2 parents 5e1a90f + 533927b commit d8d7ca2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Resources/views/Collector/swiftmailer.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@
167167
<div class="card-block">
168168
<span class="label">Alternative part ({{ messagePart.contentType }})</span>
169169
<pre>
170-
{%- if messagePart.charset %}
170+
{%- if messagePart.charset is defined and messagePart.charset %}
171171
{{- messagePart.body|convert_encoding('UTF-8', messagePart.charset) }}
172172
{%- else %}
173173
{{- messagePart.body }}

0 commit comments

Comments
 (0)