diff options
author | M.Gergo | 2018-09-15 17:40:13 +0200 |
---|---|---|
committer | M.Gergo | 2018-09-15 17:40:13 +0200 |
commit | 8147fbfa861782dd77b2a9f8734afb8e0d66d62b (patch) | |
tree | 4c17151a357488d6a7cc695166b61001a05fc5d8 | |
parent | badb74dff021171dba9578ea0cf353c6e0fa4181 (diff) | |
download | mayor-8147fbfa861782dd77b2a9f8734afb8e0d66d62b.tar.gz mayor-8147fbfa861782dd77b2a9f8734afb8e0d66d62b.zip |
occ group:add test OK
-rw-r--r-- | egyéb/nextcloud/mayor-nextcloud.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/egyéb/nextcloud/mayor-nextcloud.php b/egyéb/nextcloud/mayor-nextcloud.php index bbd4a7ec..48496bc3 100644 --- a/egyéb/nextcloud/mayor-nextcloud.php +++ b/egyéb/nextcloud/mayor-nextcloud.php @@ -289,7 +289,8 @@ if (function_exists('mysqli_connect') and PHP_MAJOR_VERSION >= 7) { //MySQLi (Im global $occ_user,$occ_path,$db,$link,$log,$m2n; $grp = nxt_group_list(); if(isset($grp[$groupName])){ - if(nxt_get_version() < 14){ // Mivel erre csak a Nextcloud 14-től van "occ" parancs, ezért néha közvetlenül kell... + if(nxt_get_version() < 14){ // Mivel erre csak a Nextcloud 14-től van "occ" parancs, ezért néha közvetlenül kell... + foreach($grp[$groupName] as $key => $user){ $e = "su -s /bin/sh $occ_user -c 'php \"".$occ_path."/occ\" group:removeuser \"$groupName\" $user'"; if($log['verbose'] > 5) { echo "bash ->\t".$e."\n"; } @@ -303,7 +304,7 @@ if (function_exists('mysqli_connect') and PHP_MAJOR_VERSION >= 7) { //MySQLi (Im } else { $e = "su -s /bin/sh $occ_user -c 'php \"".$occ_path."/occ\" group:delete \"$groupName\" '"; if($log['verbose'] > 5) { echo "bash ->\t".$e."\n"; } - shell_exec($e); + shell_exec($e); } } } |