8000 [HTTP][Session][Mongo] MongoDB driver support · symfony/symfony@211a60e · GitHub
[go: up one dir, main page]

Skip to content

Commit 211a60e

Browse files
committed
[HTTP][Session][Mongo] MongoDB driver support
1 parent 96c5eff commit 211a60e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/HttpFoundation/Session/Storage/Handler/MongoDbSessionHandler.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ public function gc($maxlifetime)
133133
if($this->getCollection() instanceof \MongoDB\Collection)
134134
{
135135
$this->getCollection()->deleteMany(array(
136-
$this->options['id_field'] => $sessionId,
136+
$this->options['expiry_field'] => array('$lt' => new \MongoDate()),
137137
));
138138
}else{
139139
$this->getCollection()->remove(array(

0 commit comments

Comments
 (0)
0