summaryrefslogtreecommitdiff
path: root/program/include/session.inc
diff options
context:
space:
mode:
authoralecpl <alec@alec.pl>2009-05-13 07:17:33 +0000
committeralecpl <alec@alec.pl>2009-05-13 07:17:33 +0000
commit27924acf437df92c4e6e88e79bd28a58e6ea4aaa (patch)
treedd1c2d11e95658bd92fa80f27188d950a630c55b /program/include/session.inc
parent1c5be6f792510c842370a2869603c6ec7ae9a29e (diff)
- speed up the whole session cleaning in kill_session()
Diffstat (limited to 'program/include/session.inc')
-rw-r--r--program/include/session.inc5
1 files changed, 4 insertions, 1 deletions
diff --git a/program/include/session.inc b/program/include/session.inc
index 7ba60412c..e19807763 100644
--- a/program/include/session.inc
+++ b/program/include/session.inc
@@ -87,10 +87,13 @@ function rcube_sess_write($key, $vars)
// unset session variable
-function rcube_sess_unset($var)
+function rcube_sess_unset($var=NULL)
{
$DB = rcmail::get_instance()->get_dbh();
+ if (empty($var))
+ return rcube_sess_destroy(session_id());
+
$now = $DB->fromunixtime(time());
$sql_result = $DB->query(