From bf1858cd4c43615ad332ae05c95b042a9188b1f6 Mon Sep 17 00:00:00 2001 From: Elliot Hesp Date: Thu, 27 Nov 2014 20:10:17 +0000 Subject: [PATCH] Simplified env detection closure --- bootstrap/start.php | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/bootstrap/start.php b/bootstrap/start.php index 7ee494d7..2d5554f6 100644 --- a/bootstrap/start.php +++ b/bootstrap/start.php @@ -25,13 +25,9 @@ $app = new Illuminate\Foundation\Application; */ $env = $app->detectEnvironment(function() { - // Take care of Heroku deployment for us. - if ($envName = getenv('ENV')) { - return $envName; - } - // Always fall back to local. - return 'local'; + // Set the environment if set, otherwise it's local + return getenv('ENV') ?: 'local'; }); /*