Skip to content

Commit fff25ce

Browse files
committed
Add a missing argument to the PdoSessionHandler.
1 parent af8c20f commit fff25ce

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

components/http_foundation/session_configuration.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,8 @@ Example usage::
8383
use Symfony\Component\HttpFoundation\Session\Storage\NativeSessionStorage;
8484
use Symfony\Component\HttpFoundation\Session\Storage\Handler\PdoSessionHandler;
8585

86-
$storage = new NativeSessionStorage(array(), new PdoSessionHandler());
86+
$pdo = new \PDO('mysql:dbname=testdb;host=127.0.0.1');
87+
$storage = new NativeSessionStorage(array(), new PdoSessionHandler($pdo));
8788
$session = new Session($storage);
8889

8990
Configuring PHP Sessions

0 commit comments

Comments
 (0)