Code

Only switch account state if allowed
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 11 Jan 2007 06:15:02 +0000 (06:15 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 11 Jan 2007 06:15:02 +0000 (06:15 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@5524 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/personal/posix/class_posixAccount.inc

index e3e9f2ab8ed457da4453466a61f77dc91347f513..ba2fdeb1e1069e4863b5d31b6066b2aee13f74f5 100644 (file)
@@ -235,7 +235,11 @@ class posixAccount extends plugin
   if(!$isCopyPaste){
     /* Do we need to flip is_account state? */
     if (isset($_POST['modify_state'])){
-      $this->is_account= !$this->is_account;
+      if($this->is_account && $this->acl == "#all#"){
+        $this->is_account= !$this->is_account;
+      }elseif(!$this->is_account && chkacl($this->acl,"create") == ""){
+        $this->is_account= !$this->is_account;
+      }
     }
 
     /* Do we represent a valid posixAccount? */