I have extended the session class as follows:
PHP Code:
require_once(BASEPATH . 'libraries/Driver.php');
require_once(BASEPATH . 'libraries/Session/Session.php');
require_once(BASEPATH . 'libraries/Session/drivers/Session_cookie.php');
class CodeIgniterSession extends CI_Session_cookie {
I load the session driver with
PHP Code:
$this->load->driver('tho/CodeIgniter/CodeIgniterSession');
and right after I try to remove userdata with
PHP Code:
$this->codeignitersession->unset_userdata('order_code');
However, this gives me the error
Quote:Fatal error: Call to a member function select_driver() on a non-object in /home/tho/Projects/Webdesign/Codeigniter 3 system/libraries/Session/Session.php on line 703
On line 703, there is the code
PHP Code:
$this->_parent->select_driver(get_class($this));
and it seems that _parent is NULL. I figured out that _parent is set through decorate(), but I couldn't figure out so far when decorate is/should be called. Adding a simple echo into the decorate function did not give me any output, which makes it seems that decorate is never called...
A bug? Or am I doing something wrong?