mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-24 06:14:25 +02:00
Loader: Fix Variable '$obj' is probably undefined
This commit is contained in:
parent
17c2a19e28
commit
fd984c5798
@ -251,6 +251,7 @@ class Loader
|
||||
return false;
|
||||
}
|
||||
|
||||
$obj = null;
|
||||
try {
|
||||
if ($this->moduleName) {
|
||||
$this->app->getModuleManager()->loadModule($this->moduleName);
|
||||
@ -267,7 +268,7 @@ class Loader
|
||||
$obj->init();
|
||||
return $obj->{$this->actionName . 'Action'}();
|
||||
} catch (Exception $e) {
|
||||
if ($obj && $obj instanceof Command && $obj->showTrace()) {
|
||||
if ($obj instanceof Command && $obj->showTrace()) {
|
||||
fwrite(STDERR, $this->formatTrace($e->getTrace()));
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user