Hi,
ich versuche für mein Test-System die gesendeten E-Mails als Datei abzulegen. In der Doku bin ich auch fündig geworden (https://docs.shopware.com/de/shopware-5-de/einstellungen/e-mails#mailversand-als-file) aber der Befehl create_function ist in PHP 7.2 deprecated.
Dann dachte ich mir, gut, machste ne anonymous function draus. Leider bekam ich dann diese Meldung:
[04-Jan-2019 08:04:07 Europe/Berlin] PHP Fatal error: Uncaught Symfony\Component\DependencyInjection\Exception\RuntimeException: Unable to dump a service container if a parameter is an object or a resource.
Hier ist der Ausschnitt aus meiner config.php:
'mail' => array(
'type' => 'file',
'path' => $this->DocPath('mails'),
'callback' => function ($transport) {
return "ShopwareMail_" . sha1($transport->body) . "_" . str_replace("@", "[at]", $transport->recipients) . ".eml";
},
),