Added Laravel's env helper

This commit is contained in:
Alejandro Celaya
2016-08-01 14:36:39 +02:00
parent d73d3049b7
commit 30988b10d1
7 changed files with 52 additions and 11 deletions

View File

@@ -25,6 +25,6 @@ class CacheFactory implements FactoryInterface
*/
public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
{
return getenv('APP_ENV') === 'pro' ? new ApcuCache() : new ArrayCache();
return env('APP_ENV', 'dev') === 'pro' ? new ApcuCache() : new ArrayCache();
}
}