Merge pull request #25 from e-picas/use-defined-acl-configfile

Fix ACL file location
This commit is contained in:
Simon DELAGE 2016-05-17 10:47:33 +02:00
commit fffefb761b
1 changed files with 3 additions and 2 deletions

View File

@ -174,7 +174,8 @@ class action_plugin_userhomepage extends DokuWiki_Action_Plugin{
if ($this->multiNsOk()) {
if ((!$this->getConf('no_acl')) && ($conf['useacl']) && ($this->userOk())) {
$existingLines = file(DOKU_CONF.'acl.auth.php');
global $config_cascade;
$existingLines = file($config_cascade['acl']['default']);
$newLines = array();
// ACL
$acl = new admin_plugin_acl();
@ -455,7 +456,7 @@ class action_plugin_userhomepage extends DokuWiki_Action_Plugin{
$groups = str_replace(' ','', $groups);
$groups = explode(',', $groups);
$userGroups = $INFO['userinfo']['grps'];
// If UHP is set to check user's group(s)
// If UHP is set to check user's group(s)
if (($groups != null) and ($groups[0] != null) and ($userGroups != null)) {
$test = array_intersect($groups, $userGroups);
// Proceed if user is member of at least one group set UHP's corresponding setting