Update deprecated calls in Model\user and mod/removeme
This commit is contained in:
@@ -57,7 +57,7 @@ function removeme_post(App $a)
|
|||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (User::authenticate($a->user, trim($_POST['qxz_password']))) {
|
if (User::getIdFromPasswordAuthentication($a->user, trim($_POST['qxz_password']))) {
|
||||||
User::remove($a->user['uid']);
|
User::remove($a->user['uid']);
|
||||||
// NOTREACHED
|
// NOTREACHED
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ use DivineOmega\PasswordExposed;
|
|||||||
use Exception;
|
use Exception;
|
||||||
use Friendica\Core\Addon;
|
use Friendica\Core\Addon;
|
||||||
use Friendica\Core\Config;
|
use Friendica\Core\Config;
|
||||||
|
use Friendica\Core\Hook;
|
||||||
use Friendica\Core\L10n;
|
use Friendica\Core\L10n;
|
||||||
use Friendica\Core\Logger;
|
use Friendica\Core\Logger;
|
||||||
use Friendica\Core\PConfig;
|
use Friendica\Core\PConfig;
|
||||||
@@ -791,7 +792,7 @@ class User
|
|||||||
|
|
||||||
$user = DBA::selectFirst('user', [], ['uid' => $uid]);
|
$user = DBA::selectFirst('user', [], ['uid' => $uid]);
|
||||||
|
|
||||||
Addon::callHooks('remove_user', $user);
|
Hook::callAll('remove_user', $user);
|
||||||
|
|
||||||
// save username (actually the nickname as it is guaranteed
|
// save username (actually the nickname as it is guaranteed
|
||||||
// unique), so it cannot be re-registered in the future.
|
// unique), so it cannot be re-registered in the future.
|
||||||
|
|||||||
Reference in New Issue
Block a user