Replace BaseObject class with DI::* calls

This commit is contained in:
nupplaPhil 2019-12-15 23:28:01 +01:00
parent 1de3f186d7
commit 388b963714
No known key found for this signature in database
GPG key ID: D8365C3D36B77D90
98 changed files with 321 additions and 440 deletions

View file

@ -7,7 +7,6 @@
namespace Friendica\Module\Security;
use Friendica\BaseModule;
use Friendica\App\Authentication;
use Friendica\Core\Config;
use Friendica\Core\Hook;
use Friendica\Core\L10n;
@ -49,15 +48,11 @@ class Login extends BaseModule
) {
$openid_url = trim(($_POST['openid_url'] ?? '') ?: $_POST['username']);
/** @var Authentication $authentication */
$authentication = self::getClass(Authentication::class);
$authentication->withOpenId($openid_url, !empty($_POST['remember']));
DI::auth()->withOpenId($openid_url, !empty($_POST['remember']));
}
if (!empty($_POST['auth-params']) && $_POST['auth-params'] === 'login') {
/** @var Authentication $authentication */
$authentication = self::getClass(Authentication::class);
$authentication->withPassword(
DI::auth()->withPassword(
DI::app(),
trim($_POST['username']),
trim($_POST['password']),