continued refactoring.

This commit is contained in:
Taylor Otwell
2011-08-31 21:57:37 -05:00
parent 61eced25a1
commit 30514d9020
7 changed files with 13 additions and 65 deletions

View File

@@ -20,6 +20,7 @@ class APC extends Driver {
* Create a new APC session driver instance.
*
* @param Cache\APC $apc
* @param int $lifetime
* @return void
*/
public function __construct(\Laravel\Cache\APC $apc, $lifetime)

View File

@@ -34,12 +34,12 @@ class Manager {
*/
public function driver($driver)
{
if (in_array($driver, array('cookie', 'file', 'database', 'apc', 'memcached')))
if ( ! $this->container->registered('laravel.session.'.$driver))
{
return $this->container->resolve('laravel.session.'.$driver);
throw new \Exception("Session driver [$driver] is not supported.");
}
throw new \Exception("Session driver [$driver] is not supported.");
return $this->container->resolve('laravel.session.'.$driver);
}
}