From 5bba56dcd8f1646888fa7218880f8e81bdf4f96f Mon Sep 17 00:00:00 2001 From: Awilum Date: Fri, 1 Feb 2019 22:18:56 +0300 Subject: [PATCH] Flextype Core: Plugins - code fixes according Scrutinizer Tests. - The variable $plugin_config does not seem to be defined for all execution paths leading up to this point. - The variable $plugin_settings does not seem to be defined for all execution paths leading up to this point. --- flextype/Plugins.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/flextype/Plugins.php b/flextype/Plugins.php index cce11524..58e0da31 100755 --- a/flextype/Plugins.php +++ b/flextype/Plugins.php @@ -259,6 +259,11 @@ class Plugins // If Plugins List isnt empty if (is_array($plugins_list) && count($plugins_list) > 0) { + // Init plugin configs + $_plugins_config = []; + $plugin_settings = []; + $plugin_config = []; + // Go through... foreach ($plugins_list as $plugin) { if (Filesystem::has($_plugin_settings = PATH['plugins'] . '/' . $plugin['dirname'] . '/settings.yaml')) {