Koha/installer/data/mysql/db_revs/210600014.pl
Jonathan Druart 8b0a44dcb5 Bug 25078: Explicitely return from DB revs to avoid warnings
% perl -wc installer/data/mysql/atomicupdate/skeleton.pl
Useless use of anonymous hash ({}) in void context at installer/data/mysql/atomicupdate/skeleton.pl

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2021-08-18 12:59:35 +02:00

22 lines
629 B
Perl
Executable file

use Modern::Perl;
return {
bug_number => "28813",
description => "Update delivery_note to failure_code in message_queue",
up => sub {
my ($args) = @_;
my $dbh = $args->{dbh};
if ( column_exists('message_queue', 'delivery_note') ) {
$dbh->do(q{
ALTER TABLE message_queue CHANGE COLUMN delivery_note failure_code MEDIUMTEXT
});
}
if( !column_exists( 'message_queue', 'failure_code' ) ) {
$dbh->do(q{
ALTER TABLE message_queue ADD failure_code mediumtext AFTER content_type
});
}
},
}