From 95504131d16a3df134cc91bda65e18f31accd921 Mon Sep 17 00:00:00 2001 From: Sukhwinder Dhillon Date: Mon, 14 Aug 2023 12:31:42 +0200 Subject: [PATCH] FormLoader: Define var `$file` in method scope - Fixes IDE's message: `varibale $file is probabaly undefined` --- library/Businessprocess/Web/Form/FormLoader.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/library/Businessprocess/Web/Form/FormLoader.php b/library/Businessprocess/Web/Form/FormLoader.php index 965da4b..0cc5389 100644 --- a/library/Businessprocess/Web/Form/FormLoader.php +++ b/library/Businessprocess/Web/Form/FormLoader.php @@ -17,6 +17,8 @@ class FormLoader $basedir = $module->getFormDir(); $ns = '\\Icinga\\Module\\' . ucfirst($module->getName()) . '\\Forms\\'; } + + $file = null; if (preg_match('~^[a-z0-9/]+$~i', $name)) { $parts = preg_split('~/~', $name); $class = ucfirst(array_pop($parts)) . 'Form';