From 482f80d14a2a001802ae14253dcf4540297cf645 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 28 Jul 2022 19:00:17 +0200 Subject: [PATCH] Close #21612 --- htdocs/core/class/commonobject.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/class/commonobject.class.php b/htdocs/core/class/commonobject.class.php index bf32aca2f57..a85a801717e 100644 --- a/htdocs/core/class/commonobject.class.php +++ b/htdocs/core/class/commonobject.class.php @@ -5470,7 +5470,7 @@ abstract class CommonObject // We save charset_output to restore it because write_file can change it if needed for // output format that does not support UTF8. - $sav_charset_output = $outputlangs->charset_output; + $sav_charset_output = empty($outputlangs->charset_output) ? '' : $outputlangs->charset_output; if (in_array(get_class($this), array('Adherent'))) { $resultwritefile = $obj->write_file($this, $outputlangs, $srctemplatepath, 'member', 1, 'tmp_cards', $moreparams);