From 8c5593b9dcedab85a7c71030db9caea662006c98 Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Thu, 20 Jun 2019 12:03:30 -0300 Subject: [PATCH] Bug 23168: Enable plugins using plain SQL Signed-off-by: Tomas Cohen Arazi --- installer/data/mysql/updatedatabase.pl | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index fb123a02b2..7c8bec4e59 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -18435,12 +18435,16 @@ if ( CheckVersion($DBversion) ) { $DBversion = '18.12.00.069'; if( CheckVersion( $DBversion ) ) { - use Koha::Plugins; - - my @plugins = Koha::Plugins->new({ enable_plugins => 1 })->GetPlugins({ all => 1 }); - foreach my $plugin ( @plugins ) { - $plugin->enable; - } + $dbh->do(q{ + INSERT INTO plugin_data + (plugin_class, plugin_key, plugin_value) + SELECT + plugin_class, + '__ENABLED__', + 1 + FROM plugin_data + WHERE plugin_key='__INSTALLED_VERSION__' + }); # Always end with this (adjust the bug info) SetVersion( $DBversion ); -- 2.22.0