aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module/Logout.php
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2018-04-11 17:40:04 -0700
committerzotlabs <mike@macgirvin.com>2018-04-11 17:40:04 -0700
commit2fa9645dfc4dc640d7460f069fc9536cce1e4fd2 (patch)
tree5a39b89802c92f32af7795050aaa3e11f9db21e6 /Zotlabs/Module/Logout.php
parent90580a860b45629f510c0cf6871fe312a9693a77 (diff)
downloadvolse-hubzilla-2fa9645dfc4dc640d7460f069fc9536cce1e4fd2.tar.gz
volse-hubzilla-2fa9645dfc4dc640d7460f069fc9536cce1e4fd2.tar.bz2
volse-hubzilla-2fa9645dfc4dc640d7460f069fc9536cce1e4fd2.zip
channel delegation: push current identity and pop it on logout from the delegated channel. This fixes the known issue of being forced to log back in after leaving the delegated channel.
Diffstat (limited to 'Zotlabs/Module/Logout.php')
-rw-r--r--Zotlabs/Module/Logout.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/Zotlabs/Module/Logout.php b/Zotlabs/Module/Logout.php
index f06e7278b..d11ce54ac 100644
--- a/Zotlabs/Module/Logout.php
+++ b/Zotlabs/Module/Logout.php
@@ -5,7 +5,12 @@ namespace Zotlabs\Module;
class Logout extends \Zotlabs\Web\Controller {
function init() {
- \App::$session->nuke();
+ if($_SESSION['delegate'] && $_SESSION['delegate_push']) {
+ $_SESSION = $_SESSION['delegate_push'];
+ }
+ else {
+ \App::$session->nuke();
+ }
goaway(z_root());
}