mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-08 09:54:28 +02:00
UserSession class [5] - Refactor src/Module/ files with DI
This commit is contained in:
parent
a729f3255d
commit
eecc456e0c
78 changed files with 455 additions and 530 deletions
|
@ -27,7 +27,6 @@ use Friendica\Core\Config\Capability\IManageConfigValues;
|
|||
use Friendica\Core\Hook;
|
||||
use Friendica\Core\L10n;
|
||||
use Friendica\Core\Renderer;
|
||||
use Friendica\Core\Session;
|
||||
use Friendica\Core\Session\Capability\IHandleSessions;
|
||||
use Friendica\DI;
|
||||
use Friendica\Module\Register;
|
||||
|
@ -63,7 +62,7 @@ class Login extends BaseModule
|
|||
{
|
||||
$return_path = $request['return_path'] ?? $this->session->pop('return_path', '') ;
|
||||
|
||||
if (Session::getLocalUser()) {
|
||||
if (DI::userSession()->getLocalUserId()) {
|
||||
$this->baseUrl->redirect($return_path);
|
||||
}
|
||||
|
||||
|
@ -127,7 +126,7 @@ class Login extends BaseModule
|
|||
];
|
||||
}
|
||||
|
||||
if (Session::getLocalUser()) {
|
||||
if (DI::userSession()->getLocalUserId()) {
|
||||
$tpl = Renderer::getMarkupTemplate('logout.tpl');
|
||||
} else {
|
||||
DI::page()['htmlhead'] .= Renderer::replaceMacros(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue