Use sudo rm --recursive for /srv/niver/ht/username
This commit is contained in:
parent
e7b2856f92
commit
72f4ce3605
|
@ -30,7 +30,9 @@ if (processForm()) {
|
|||
|
||||
removeDirectory(CONF['ht']['tor_config_path'] . '/' . $_SESSION['username']);
|
||||
|
||||
removeDirectory(CONF['ht']['ht_path'] . '/' . $_SESSION['username']);
|
||||
exec(CONF['ht']['sudo_path'] . ' ' . CONF['ht']['rm_path'] . ' --recursive ' . CONF['ht']['ht_path'] . '/' . $_SESSION['username'], result_code: $code);
|
||||
if ($code !== 0)
|
||||
serverError("Can't remove user's directory.");
|
||||
|
||||
query('delete', 'users', ['username' => $_SESSION['username']]);
|
||||
|
||||
|
|
Loading…
Reference in New Issue