From ab7c51c13324db5af2f7c6a3856f41f742c6c8d6 Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Wed, 5 Jun 2019 14:55:17 +0200 Subject: [PATCH] Periodische Rechnungen: find_template-Aufruf gefit MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit find_template gibt je nach Kontext (Skalar vs. Array) unterschiedliche Dinge zurück. Innerhalb einer Hashzuweisung herrscht Array-Kontext, und damit kann je nach Reihenfolge, in der die Hash-Parameter von Perl ausgewertet werden, der gesamte Hashinhalt schrott sein. --- SL/BackgroundJob/CreatePeriodicInvoices.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SL/BackgroundJob/CreatePeriodicInvoices.pm b/SL/BackgroundJob/CreatePeriodicInvoices.pm index 5020313d2..aeb0444c0 100644 --- a/SL/BackgroundJob/CreatePeriodicInvoices.pm +++ b/SL/BackgroundJob/CreatePeriodicInvoices.pm @@ -383,7 +383,7 @@ sub _email_invoice { return unless @recipients; my %create_params = ( - template => $self->find_template(name => 'invoice'), + template => scalar($self->find_template(name => 'invoice')), variables => Form->new(''), return => 'file_name', variable_content_types => { -- 2.20.1