Private GIT

Skip to content
Snippets Groups Projects
Commit 64fd6025 authored by Kevin Duret's avatar Kevin Duret
Browse files

fix clapi require libs

parent 11e91844
Branches
Tags
No related merge requests found
......@@ -369,7 +369,8 @@ class CentreonAPI
if ($object != "") {
if (isset($this->relationObject[$object]['class'])
&& isset($this->relationObject[$object]['module'])
&& !class_exists("Centreon" . $this->relationObject[$object]['class'])) {
&& !class_exists("\CentreonClapi\Centreon" . $this->relationObject[$object]['class'])
) {
if ($this->relationObject[$object]['module'] == 'core') {
require_once "centreon" . $this->relationObject[$object]['class'] . ".class.php";
} else {
......@@ -389,7 +390,8 @@ class CentreonAPI
foreach ($this->relationObject as $sSynonyme => $oObjet) {
if (isset($oObjet['class'])
&& isset($oObjet['module'])
&& !class_exists("\CentreonClapi\Centreon" . $oObjet['class'])) {
&& !class_exists("\CentreonClapi\Centreon" . $oObjet['class'])
) {
if ($oObjet['module'] == 'core') {
require_once _CENTREON_PATH_
. "www/class/centreon-clapi/centreon"
......@@ -642,7 +644,6 @@ class CentreonAPI
$objName = "";
}
if (!isset($this->relationObject[$this->object]['class']) || !class_exists($objName)) {
print "Object $this->object not found in Centreon API.\n";
return 1;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment