Skip to content

Commit 1a53917

Browse files
committed
bug #5589 [Cookbook][Session] fix default expiry field name (xabbuh)
This PR was merged into the 2.3 branch. Discussion ---------- [Cookbook][Session] fix default expiry field name | Q | A | ------------- | --- | Doc fix? | yes | New docs? | no | Applies to | all | Fixed tickets | As @stevenmusumeche noted in #5478 (comment), the [default expiry field name is expires_at](https://github.com/symfony/symfony/blob/2.8/src/Symfony/Component/HttpFoundation/Session/Storage/Handler/MongoDbSessionHandler.php#L86). Commits ------- 1e1a129 [Cookbook][Session] fix default expiry field name
2 parents a265de1 + 1e1a129 commit 1a53917

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cookbook/doctrine/mongodb_session_storage.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ From the `MongoDB shell`_:
165165
.. code-block:: sql
166166
167167
use session_db
168-
db.session.ensureIndex( { "expireAt": 1 }, { expireAfterSeconds: 0 } )
168+
db.session.ensureIndex( { "expires_at": 1 }, { expireAfterSeconds: 0 } )
169169
170170
.. _installed and configured a MongoDB server: http://docs.mongodb.org/manual/installation/
171171
.. _MongoDB shell: http://docs.mongodb.org/v2.2/tutorial/getting-started-with-the-mongo-shell/

0 commit comments

Comments
 (0)