From 4774b198f28b2c29b9ab2bed7d69230fb46cc8f7 Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Fri, 30 May 2025 11:41:34 -0300 Subject: [PATCH] Bug 40037: (follow-up) Remove redundancy in `before_send_messages` Signed-off-by: Tomas Cohen Arazi --- C4/Letters.pm | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/C4/Letters.pm b/C4/Letters.pm index c90f335f2b4..b1ac8db59c5 100644 --- a/C4/Letters.pm +++ b/C4/Letters.pm @@ -1058,15 +1058,13 @@ sub SendQueuedMessages { } ); - if (@plugins) { - foreach my $plugin (@plugins) { - try { - $plugin->before_send_messages($params); - } catch { - warn "$_"; - exit 1 if $params->{exit_on_plugin_failure}; - }; - } + foreach my $plugin (@plugins) { + try { + $plugin->before_send_messages($params); + } catch { + warn "$_"; + exit 1 if $params->{exit_on_plugin_failure}; + }; } } -- 2.49.0