/** * destroy the current session * * @access public * @return Fuel\Core\Session_Redis */ public function destroy() { // do we have something to destroy? if (!empty($this->keys)) { // delete the key from the redis server $this->redis->del($this->keys['session_id']); } parent::destroy(); return $this; }
/** * destroy the current session * * @access public * @return Fuel\Core\Session_Memcached */ public function destroy() { // do we have something to destroy? if (!empty($this->keys)) { // delete the key from the memcached server if ($this->memcached->delete($this->config['cookie_name'] . '_' . $this->keys['session_id']) === false) { throw new \FuelException('Memcached returned error code "' . $this->memcached->getResultCode() . '" on delete. Check your configuration.'); } } parent::destroy(); return $this; }
/** * destroy the current session * * @access public * @return Fuel\Core\Session_Db */ public function destroy() { // do we have something to destroy? if (!empty($this->keys) and !empty($this->record)) { // delete the session record $result = \DB::delete($this->config['table'])->where('session_id', '=', $this->keys['session_id'])->execute($this->config['database']); } // reset the stored session data $this->record = null; parent::destroy(); return $this; }
/** * destroy the current session * * @access public * @return Fuel\Core\Session_File */ public function destroy() { // do we have something to destroy? if (!empty($this->keys)) { // delete the session file $file = $this->config['path'] . $this->config['cookie_name'] . '_' . $this->keys['session_id']; if (is_file($file)) { unlink($file); } } parent::destroy(); return $this; }