From 5eb524b21ab0811d01c031567c81d49979d6b191 Mon Sep 17 00:00:00 2001 From: Olav Morken <olav.morken@uninett.no> Date: Fri, 2 Dec 2011 10:47:44 +0000 Subject: [PATCH] frontpage: Only show warnings about ldap & radius if those modules are enabled. Thanks to Gordon Franke for providing this fix! git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@2993 44740490-163a-0410-bde0-09ae8108e29a --- modules/core/www/frontpage_config.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/modules/core/www/frontpage_config.php b/modules/core/www/frontpage_config.php index 84f0d22f1..392ee1815 100644 --- a/modules/core/www/frontpage_config.php +++ b/modules/core/www/frontpage_config.php @@ -81,11 +81,16 @@ $functionchecks = array( 'simplexml_import_dom' => array('required', 'SimpleXML'), 'dom_import_simplexml' => array('required', 'XML DOM'), 'preg_match' => array('required', 'RegEx support'), - 'ldap_bind' => array('required_ldap', 'LDAP Extension'), - 'radius_auth_open' => array('required_radius', 'Radius Extension'), 'mcrypt_module_open'=> array('optional', 'MCrypt'), 'mysql_connect' => array('optional', 'MySQL support'), ); +if (SimpleSAML_Module::isModuleEnabled('ldap')) { + $functionchecks['ldap_bind'] = array('required_ldap', 'LDAP Extension'); +} +if (SimpleSAML_Module::isModuleEnabled('radius')) { + $functionchecks['radius_auth_open'] = array('required_radius', 'Radius Extension'); +} + $funcmatrix = array(); $funcmatrix[] = array( 'required' => 'required', -- GitLab