From cad7e534a42219f277928dfa53ac0a2b9a31a562 Mon Sep 17 00:00:00 2001 From: nupplaPhil Date: Tue, 10 Dec 2019 00:50:05 +0100 Subject: [PATCH] Add phpdoc --- src/Core/Session/ISession.php | 5 +++-- src/Core/Session/MemorySession.php | 2 -- src/Core/Session/NativeSession.php | 5 +++-- src/Factory/SessionFactory.php | 3 +++ 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/src/Core/Session/ISession.php b/src/Core/Session/ISession.php index 006cc6ce6a..a2046e915c 100644 --- a/src/Core/Session/ISession.php +++ b/src/Core/Session/ISession.php @@ -2,8 +2,9 @@ namespace Friendica\Core\Session; -use Friendica\BaseObject; - +/** + * Contains all global supported Session methods + */ interface ISession { /** diff --git a/src/Core/Session/MemorySession.php b/src/Core/Session/MemorySession.php index 08838c433f..eee481d3b0 100644 --- a/src/Core/Session/MemorySession.php +++ b/src/Core/Session/MemorySession.php @@ -3,8 +3,6 @@ namespace Friendica\Core\Session; /** - * Native Session functions for internal Session usage. - * * Usable for backend processes (daemon/worker) and testing */ final class MemorySession implements ISession diff --git a/src/Core/Session/NativeSession.php b/src/Core/Session/NativeSession.php index 2c1507dd15..49278ed4a6 100644 --- a/src/Core/Session/NativeSession.php +++ b/src/Core/Session/NativeSession.php @@ -6,6 +6,9 @@ use Friendica\Core\Config\Configuration; use Friendica\App; use Friendica\Model\User\Cookie; +/** + * The native Session class which uses the PHP internal Session function + */ class NativeSession implements ISession { /** @var Cookie */ @@ -88,7 +91,5 @@ class NativeSession implements ISession { $this->cookie->clear(); $_SESSION = []; - session_unset(); - session_destroy(); } } diff --git a/src/Factory/SessionFactory.php b/src/Factory/SessionFactory.php index ed2f787b42..999c424c99 100644 --- a/src/Factory/SessionFactory.php +++ b/src/Factory/SessionFactory.php @@ -18,6 +18,9 @@ use Friendica\Model\User\Cookie; use Friendica\Util\Profiler; use Psr\Log\LoggerInterface; +/** + * Factory for creating a valid Session for this run + */ class SessionFactory { /** @var string The plain, PHP internal session management */