From b86a54ad73bcb9dcf4665f12d1a821413cce58ca Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Wed, 23 Jun 2021 12:16:11 +0100 Subject: [PATCH] Bug 25078: (follow-up) Update 'NewVersion' for output_version changes This patch updates the NewVersion compatability method to add arrayref description handling to split it into description + report. Signed-off-by: Martin Renvoize Signed-off-by: Kyle M Hall Signed-off-by: Jonathan Druart --- C4/Installer.pm | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/C4/Installer.pm b/C4/Installer.pm index 203d175c13..7523cd8395 100644 --- a/C4/Installer.pm +++ b/C4/Installer.pm @@ -869,13 +869,19 @@ sub NewVersion { SetVersion($DBversion); - unless ( ref($descriptions) ) { - $descriptions = [ $descriptions ]; + my ( $description, $report ); + if ( ref($descriptions) ) { + $description = shift @$descriptions; + $report = join( "\n", @{$descriptions} ); + } + else { + $description = $descriptions; } my $output = output_version( { bug_number => $bug_number, - description => $descriptions, + description => $description, + report => $report, version => $DBversion, time => POSIX::strftime( "%H:%M:%S", localtime ), }); -- 2.39.5