2
0
Эх сурвалжийг харах

[Web] Fix logout after oauth2

andryyy 5 жил өмнө
parent
commit
c3c584a075

+ 4 - 0
data/web/oauth/profile.php

@@ -22,6 +22,10 @@ if (!empty($mailbox)) {
       'modified' => (!empty($mailbox['modified']) ? $mailbox['modified'] : ''),
       'modified' => (!empty($mailbox['modified']) ? $mailbox['modified'] : ''),
       'active' => (!empty($mailbox['active']) ? $mailbox['active'] : ''),
       'active' => (!empty($mailbox['active']) ? $mailbox['active'] : ''),
     ));
     ));
+    if ($GLOBALS['OAUTH2_FORGET_SESSION_AFTER_LOGIN'] === true) {
+      session_unset();
+      session_destroy();
+    }
     exit;
     exit;
   }
   }
   if ($GLOBALS['OAUTH2_FORGET_SESSION_AFTER_LOGIN'] === true) {
   if ($GLOBALS['OAUTH2_FORGET_SESSION_AFTER_LOGIN'] === true) {