From b4be89bdac46af2b1370ea25268159c2cf2cc632 Mon Sep 17 00:00:00 2001 From: corbosman <cor@xs4all.net> Date: Fri, 27 Feb 2015 09:03:58 -0500 Subject: [PATCH] use factory --- program/lib/Roundcube/rcube_session_memcache.php | 12 ++++++++---- 1 files changed, 8 insertions(+), 4 deletions(-) diff --git a/program/lib/Roundcube/rcube_session_memcache.php b/program/lib/Roundcube/rcube_session_memcache.php index 85a4aa6..732d5fb 100644 --- a/program/lib/Roundcube/rcube_session_memcache.php +++ b/program/lib/Roundcube/rcube_session_memcache.php @@ -15,7 +15,7 @@ +-----------------------------------------------------------------------+ | Author: Thomas Bruederli <roundcube@gmail.com> | | Author: Aleksander Machniak <alec@alec.pl> | - | Author: Cor Bosman <cor@roundcu.be> | + | Author: Cor Bosman <cor@roundcu.bet> | +-----------------------------------------------------------------------+ */ @@ -32,11 +32,16 @@ { private $memcache; - public function __construct() + /** + * @param Object $config + */ + public function __construct($config) { + parent::__construct($config); + $this->memcache = rcube::get_instance()->get_memcache(); - if(! $this->memcache) { + if (!$this->memcache) { rcube::raise_error(array('code' => 604, 'type' => 'db', 'line' => __LINE__, 'file' => __FILE__, 'message' => "Failed to connect to memcached. Please check configuration"), @@ -45,7 +50,6 @@ // register sessions handler $this->register_session_handler(); - } /** -- Gitblit v1.9.1