summaryrefslogtreecommitdiff
path: root/inc/confutils.php
diff options
context:
space:
mode:
authorAdrian Lang <mail@adrianlang.de>2011-04-22 22:35:43 +0200
committerAdrian Lang <mail@adrianlang.de>2011-04-22 22:35:43 +0200
commit8ccf9c9785ec2b626bad30a88a21f02886845418 (patch)
tree0ecd6103880e3350bd37ba11ae3872805ede1755 /inc/confutils.php
parente2092379b1c3200832cb569781ec647db5aeef0f (diff)
parent23d27376b2a2f6a1ccf0777c48435717494d85b1 (diff)
downloadrpg-8ccf9c9785ec2b626bad30a88a21f02886845418.tar.gz
rpg-8ccf9c9785ec2b626bad30a88a21f02886845418.tar.bz2
Merge branch 'master' into stable
Conflicts: data/deleted.files doku.php lib/exe/xmlrpc.php
Diffstat (limited to 'inc/confutils.php')
-rw-r--r--inc/confutils.php23
1 files changed, 15 insertions, 8 deletions
diff --git a/inc/confutils.php b/inc/confutils.php
index 4306dab8f..29ead1e9f 100644
--- a/inc/confutils.php
+++ b/inc/confutils.php
@@ -241,17 +241,24 @@ function actionOK($action){
// prepare disabled actions array and handle legacy options
$disabled = explode(',',$conf['disableactions']);
$disabled = array_map('trim',$disabled);
- if(isset($conf['openregister']) && !$conf['openregister']) $disabled[] = 'register';
- if(isset($conf['resendpasswd']) && !$conf['resendpasswd']) $disabled[] = 'resendpwd';
- if(isset($conf['subscribers']) && !$conf['subscribers']) {
- $disabled[] = 'subscribe';
- }
- if (is_null($auth) || !$auth->canDo('addUser')) {
+ if((isset($conf['openregister']) && !$conf['openregister']) || is_null($auth) || !$auth->canDo('addUser')) {
$disabled[] = 'register';
}
- if (is_null($auth) || !$auth->canDo('modPass')) {
+ if((isset($conf['resendpasswd']) && !$conf['resendpasswd']) || is_null($auth) || !$auth->canDo('modPass')) {
$disabled[] = 'resendpwd';
}
+ if((isset($conf['subscribers']) && !$conf['subscribers']) || is_null($auth)) {
+ $disabled[] = 'subscribe';
+ }
+ if (is_null($auth) || !$auth->canDo('Profile')) {
+ $disabled[] = 'profile';
+ }
+ if (is_null($auth)) {
+ $disabled[] = 'login';
+ }
+ if (is_null($auth) || !$auth->canDo('logout')) {
+ $disabled[] = 'logout';
+ }
$disabled = array_unique($disabled);
}
@@ -324,4 +331,4 @@ function conf_decodeString($str) {
return $str;
}
}
-//Setup VIM: ex: et ts=4 enc=utf-8 :
+//Setup VIM: ex: et ts=4 :