X-Git-Url: http://source.bookstackapp.com/bookstack/blobdiff_plain/ed88c623d6231230e513a087cada8eae569292a8..refs/pull/2023/head:/public/index.php diff --git a/public/index.php b/public/index.php index 904bd999b..820576472 100644 --- a/public/index.php +++ b/public/index.php @@ -11,17 +11,15 @@ define('LARAVEL_START', microtime(true)); /* |-------------------------------------------------------------------------- -| Register The Auto Loader +| Initialize The App |-------------------------------------------------------------------------- | -| Composer provides a convenient, automatically generated class loader for -| our application. We just need to utilize it! We'll simply require it -| into the script here so that we don't have to worry about manual -| loading any of our classes later on. It feels great to relax. +| We need to get things going before we start up the app. +| The init file loads everything in, in the correct order. | */ -require __DIR__.'/../vendor/autoload.php'; +require __DIR__.'/../bootstrap/init.php'; /* |-------------------------------------------------------------------------- @@ -36,6 +34,7 @@ require __DIR__.'/../vendor/autoload.php'; */ $app = require_once __DIR__.'/../bootstrap/app.php'; +$app->alias('request', \BookStack\Http\Request::class); /* |-------------------------------------------------------------------------- @@ -52,7 +51,7 @@ $app = require_once __DIR__.'/../bootstrap/app.php'; $kernel = $app->make(Illuminate\Contracts\Http\Kernel::class); $response = $kernel->handle( - $request = Illuminate\Http\Request::capture() + $request = \BookStack\Http\Request::capture() ); $response->send();