From: Gunnar Wrobel
Date: Wed, 3 Mar 2010 10:28:36 +0000 (+0100)
Subject: Move the authentication check and restoring the tasklist from the session into the...
X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=d9e424ecc4b2e1de88fb2e98b32024482ea37231;p=horde.git
Move the authentication check and restoring the tasklist from the session into the backend.
---
diff --git a/framework/LoginTasks/lib/Horde/LoginTasks.php b/framework/LoginTasks/lib/Horde/LoginTasks.php
index 4310b63e2..35fbfe9c2 100644
--- a/framework/LoginTasks/lib/Horde/LoginTasks.php
+++ b/framework/LoginTasks/lib/Horde/LoginTasks.php
@@ -78,7 +78,7 @@ class Horde_LoginTasks
{
if (empty(self::$_instances[$app])) {
self::$_instances[$app] = new self(
- new Horde_LoginTasks_Backend_Horde(), $app
+ new Horde_LoginTasks_Backend_Horde($app), $app
);
}
@@ -98,14 +98,12 @@ class Horde_LoginTasks
$this->_app = $app;
- if (!Horde_Auth::getAuth()) {
+ if (!$this->_backend->isAuthenticated()) {
return;
}
/* Retrieves a cached tasklist or make sure one is created. */
- if (isset($_SESSION['horde_logintasks'][$app])) {
- $this->_tasklist = @unserialize($_SESSION['horde_logintasks'][$app]);
- }
+ $this->_tasklist = $this->_backend->getTaskListFromCache();
if (empty($this->_tasklist)) {
$this->_createTaskList();
diff --git a/framework/LoginTasks/lib/Horde/LoginTasks/Backend.php b/framework/LoginTasks/lib/Horde/LoginTasks/Backend.php
index 5d41ffc21..150260af0 100644
--- a/framework/LoginTasks/lib/Horde/LoginTasks/Backend.php
+++ b/framework/LoginTasks/lib/Horde/LoginTasks/Backend.php
@@ -13,6 +13,20 @@
* @author Gunnar Wrobel