summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandi <andi@splitbrain.org>2005-06-08 23:09:12 +0200
committerandi <andi@splitbrain.org>2005-06-08 23:09:12 +0200
commitbdbc16bf99bf53145b1f6d4979326c69f1af2d35 (patch)
tree9a70b8b38607b9e284c1aea0717489c1cb8b7d69
parentfedfd84a756cab6c7e2dd632278fa6a93dbc4dd7 (diff)
downloadrpg-bdbc16bf99bf53145b1f6d4979326c69f1af2d35.tar.gz
rpg-bdbc16bf99bf53145b1f6d4979326c69f1af2d35.tar.bz2
Allow source view with read only permissions #383
darcs-hash:20050608210912-9977f-d7645e56001efd2ee6b08504a15ff7f293d8ae92.gz
-rw-r--r--inc/actions.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/inc/actions.php b/inc/actions.php
index aef63b94c..09042885e 100644
--- a/inc/actions.php
+++ b/inc/actions.php
@@ -116,7 +116,13 @@ function act_permcheck($act){
if(in_array($act,array('save','preview','edit'))){
if($INFO['exists']){
- $permneed = AUTH_EDIT;
+ if($act == 'edit'){
+ //the edit function will check again and do a source show
+ //when no AUTH_EDIT available
+ $permneed = AUTH_READ;
+ }else{
+ $permneed = AUTH_EDIT;
+ }
}else{
$permneed = AUTH_CREATE;
}