]> git.mxchange.org Git - core.git/blobdiff - framework/main/classes/class_BaseFrameworkSystem.php
Continued:
[core.git] / framework / main / classes / class_BaseFrameworkSystem.php
index 6810e7244d653fb908b8accf5138b3e2ffdb4190..7c6a73f92d16b56b467dce7136b54cd3719863af 100644 (file)
@@ -618,8 +618,11 @@ Loaded includes:
         * @deprecated  Not fully, as the new Logger facilities are not finished yet.
         */
        public final static function createDebugInstance (string $className, int $lineNumber = NULL) {
-               // Is the instance set?
-               if (!GenericRegistry::getRegistry()->instanceExists('debug')) {
+               // Validate parameter
+               if (empty($className)) {
+                       // Throw IAE
+                       throw new InvalidArgumentException('Parameter "className" is empty');
+               } elseif (!GenericRegistry::getRegistry()->instanceExists('debug')) {
                        // Init debug instance
                        $debugInstance = NULL;