| */ use Symfony\Component\HttpFoundation\LaravelRequest as RequestFoundation; Request::$foundation = RequestFoundation::createFromGlobals(); /* |-------------------------------------------------------------------------- | Determine The Application Environment |-------------------------------------------------------------------------- | | Next we're ready to determine the application environment. This may be | set either via the command line options, or, if the request is from | the web, via the mapping of URIs to environments that lives in | the "paths.php" file for the application and is parsed. | */ if (Request::cli()) { $environment = get_cli_option('env'); } else { $root = Request::foundation()->getRootUrl(); $environment = Request::detect_env($environments, $root); } /* |-------------------------------------------------------------------------- | Set The Application Environment |-------------------------------------------------------------------------- | | Once we have determined the application environment, we will set it on | the global server array of the HttpFoundation request. This makes it | available throughout the application, thought it is mainly only | used to determine which configuration files to merge in. |