Commit f9837f85 authored by Dave Marshall's avatar Dave Marshall

Switch to FileSessionHandler, NativeFileSessionHandler remove upstream

parent e9af894a
...@@ -8,7 +8,7 @@ Parameters ...@@ -8,7 +8,7 @@ Parameters
---------- ----------
* **session.storage.save_path** (optional): The path for the * **session.storage.save_path** (optional): The path for the
``NativeFileSessionHandler``, defaults to the value of ``FileSessionHandler``, defaults to the value of
``sys_get_temp_dir()``. ``sys_get_temp_dir()``.
* **session.storage.options**: An array of options that is passed to the * **session.storage.options**: An array of options that is passed to the
...@@ -38,7 +38,7 @@ Services ...@@ -38,7 +38,7 @@ Services
* **session.storage.handler**: A service that is used by the * **session.storage.handler**: A service that is used by the
``session.storage`` for data access. Defaults to a ``session.storage`` for data access. Defaults to a
``NativeFileSessionHandler`` storage handler. ``FileSessionHandler`` storage handler.
Registering Registering
----------- -----------
......
...@@ -14,7 +14,7 @@ namespace Silex\Provider; ...@@ -14,7 +14,7 @@ namespace Silex\Provider;
use Silex\Application; use Silex\Application;
use Silex\ServiceProviderInterface; use Silex\ServiceProviderInterface;
use Symfony\Component\HttpFoundation\Session\Storage\Handler\NativeFileSessionHandler; use Symfony\Component\HttpFoundation\Session\Storage\Handler\FileSessionHandler;
use Symfony\Component\HttpFoundation\Session\Storage\NativeSessionStorage; use Symfony\Component\HttpFoundation\Session\Storage\NativeSessionStorage;
use Symfony\Component\HttpFoundation\Session\Session; use Symfony\Component\HttpFoundation\Session\Session;
use Symfony\Component\HttpKernel\KernelEvents; use Symfony\Component\HttpKernel\KernelEvents;
...@@ -37,7 +37,7 @@ class SessionServiceProvider implements ServiceProviderInterface ...@@ -37,7 +37,7 @@ class SessionServiceProvider implements ServiceProviderInterface
}); });
$app['session.storage.handler'] = $app->share(function () use ($app) { $app['session.storage.handler'] = $app->share(function () use ($app) {
return new NativeFileSessionHandler( return new FileSessionHandler(
isset($app['session.storage.save_path']) ? $app['session.storage.save_path'] : null isset($app['session.storage.save_path']) ? $app['session.storage.save_path'] : null
); );
}); });
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment