mirror of
https://github.com/friendica/friendica
synced 2025-04-25 19:10:11 +00: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
|
@ -22,7 +22,6 @@
|
|||
namespace Friendica\Module;
|
||||
|
||||
use Friendica\BaseModule;
|
||||
use Friendica\Core\Session;
|
||||
use Friendica\Core\System;
|
||||
use Friendica\Database\DBA;
|
||||
use Friendica\DI;
|
||||
|
@ -43,7 +42,7 @@ class NoScrape extends BaseModule
|
|||
if (isset($this->parameters['nick'])) {
|
||||
// Get infos about a specific nick (public)
|
||||
$which = $this->parameters['nick'];
|
||||
} elseif (Session::getLocalUser() && isset($this->parameters['profile']) && DI::args()->get(2) == 'view') {
|
||||
} elseif (DI::userSession()->getLocalUserId() && isset($this->parameters['profile']) && DI::args()->get(2) == 'view') {
|
||||
// view infos about a known profile (needs a login)
|
||||
$which = $a->getLoggedInUserNickname();
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue