Improving exception message
Publish PHP Package / docker (push) Successful in 5s
Details
Publish PHP Package / docker (push) Successful in 5s
Details
This commit is contained in:
parent
ff4ae2682c
commit
0abaa301c3
|
@ -1028,7 +1028,7 @@ function config_load_ex(string $conf_dir, string $file, array $arr, ?int $id = n
|
|||
throw new Exception("No such class '$klass'");
|
||||
$cnf = new $klass;
|
||||
if(!is_a($cnf, $GLOBALS['CONFIG_BASE_CLASS']))
|
||||
throw new Exception("Class '$klass' must inherit from '{$GLOBALS['CONFIG_BASE_CLASS']}'");
|
||||
throw new Exception("'$klass' is not subclass of '".ltrim($GLOBALS['CONFIG_BASE_CLASS'], '\\')."'");
|
||||
|
||||
$cnf->import($arr, true);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue