From 3a9b5484d099187c5b4b9052fe85554589d7e4de Mon Sep 17 00:00:00 2001 From: Magnus Enger Date: Tue, 18 Oct 2016 09:47:19 +0000 Subject: [PATCH] Bug 17461 - Warn about plugins that can't be loaded The logs should have some info if a module has been installed that can not be loaded. To test: - Make sure you have an up to date dev install - Install v1.0 of the KitchenSink plugin from https://github.com/bywatersolutions/koha-plugin-kitchen-sink/releases - Make sure the plugin does not show up in the list of installed plugins, and that the intranet-error.log has no info about it - Apply the patch - Reload plugins-home.pl - Verify that there is now some interesting info in intranet-error.log --- Koha/Plugins.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Koha/Plugins.pm b/Koha/Plugins.pm index c0598b1..6f66098 100644 --- a/Koha/Plugins.pm +++ b/Koha/Plugins.pm @@ -84,6 +84,8 @@ sub GetPlugins { and %$req_metadata and any { !$plugin_metadata->{$_} || $plugin_metadata->{$_} ne $req_metadata->{$_} } keys %$req_metadata; push @plugins, $plugin; + } else { + warn $Module::Load::Conditional::ERROR; } } return @plugins; -- 2.1.4