summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 60607f1)
raw | patch | inline | side by side (parent: 60607f1)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 27 May 2010 14:15:15 +0000 (14:15 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 27 May 2010 14:15:15 +0000 (14:15 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@18776 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-core/include/class_configRegistry.inc | patch | blob | history |
diff --git a/gosa-core/include/class_configRegistry.inc b/gosa-core/include/class_configRegistry.inc
index ac9ba95628680c3f04419f6fcd80ba6c475c83cc..048af50c76f44fc08cabbf40ad26ce69366ece00 100644 (file)
}
+
function validateSchemata($force = FALSE, $disableIncompatiblePlugins = FALSE)
{
- // We can check the schemata only with a valid LDAP connection
- if(empty($this->config->current['CONFIG'])){
+ // Read objectClasses from ldap
+ if(!count($this->objectClasses)){
+ $ldap = $this->config->get_ldap_link();
+ $ldap->cd($this->config->current['BASE']);
+ $this->setObjectClasses($ldap->get_objectclasses());
+ }
+
+ return($this->_validateSchemata($force, $disableIncompatiblePlugins));
+ }
+
+ function setObjectClasses($ocs)
+ {
+ $this->objectClasses = $ocs;
+ }
+
+ function getSchemaResults()
+ {
+ return($this->detectedSchemaIssues);
+ }
+
+ function _validateSchemata($force = FALSE, $disableIncompatiblePlugins = FALSE)
+ {
+ // We cannot check without readable schema info
+ if(!count($this->objectClasses)){
return(TRUE);
}
// Clear last results
$this->pluginsDeactivated = array();
- // Read objectClasses from ldap
- if(!count($this->objectClasses)){
- $ldap = $this->config->get_ldap_link();
- $ldap->cd($this->config->current['BASE']);
- $this->objectClasses = $ldap->get_objectclasses();
- }
-
// Collect required schema infos
$this->pluginRequirements = array('ldapSchema' => array());
$this->categoryToClass = array();
$this->properties = array();
$this->mapByName = array();
+ if(!$this->config) return;
+
// Search for config flags defined in the config file (TAB section)
foreach($this->config->data['TABS'] as $tabname => $tabdefs){
foreach($tabdefs as $info){