|
@@ -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']]);
|
|
|
|