From 20f1ab05e64af8f968d9bce87e5fcb963d5a4d2c Mon Sep 17 00:00:00 2001 From: nupplaPhil Date: Tue, 7 Jan 2020 00:10:15 +0100 Subject: [PATCH] clear cookie before session clear --- src/DI.php | 2 ++ src/Module/Security/Logout.php | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/DI.php b/src/DI.php index e328a1fdd3..485b1b799d 100644 --- a/src/DI.php +++ b/src/DI.php @@ -28,6 +28,7 @@ use Psr\Log\LoggerInterface; * @method static Core\Process process() * @method static Core\Session\ISession session() * @method static Database\Database dba() + * @method static Model\User\Cookie cookie() * @method static Model\Notify notify() * @method static Model\Introduction intro() * @method static Protocol\Activity activity() @@ -61,6 +62,7 @@ abstract class DI 'process' => Core\Process::class, 'session' => Core\Session\ISession::class, 'dba' => Database\Database::class, + 'cookie' => Model\User\Cookie::class, 'notify' => Model\Notify::class, 'intro' => Model\Introduction::class, 'activity' => Protocol\Activity::class, diff --git a/src/Module/Security/Logout.php b/src/Module/Security/Logout.php index abe409ca1d..cc236bf304 100644 --- a/src/Module/Security/Logout.php +++ b/src/Module/Security/Logout.php @@ -6,7 +6,6 @@ namespace Friendica\Module\Security; use Friendica\BaseModule; -use Friendica\App\Authentication; use Friendica\Core\Cache; use Friendica\Core\Hook; use Friendica\Core\L10n; @@ -34,6 +33,7 @@ class Logout extends BaseModule } Hook::callAll("logging_out"); + DI::cookie()->clear(); Session::clear(); if ($visitor_home) {