Use new middleware for faking HTTP headers

pull/19/head
Franz Liedke 2015-09-25 00:32:32 +02:00
parent 5f0315d0fc
commit c29323b3f4
1 changed files with 1 additions and 0 deletions

View File

@ -22,6 +22,7 @@ $app->register('Flarum\Api\ApiServiceProvider');
$api = new MiddlewarePipe();
$api->pipe($app->make('Flarum\Api\Middleware\ReadJsonParameters'));
$api->pipe($app->make('Flarum\Api\Middleware\LoginWithHeader'));
$api->pipe($app->make('Flarum\Api\Middleware\FakeHttpMethods'));
$apiPath = parse_url(Core::url('api'), PHP_URL_PATH);
$router = $app->make('Flarum\Http\RouterMiddleware', ['routes' => $app->make('flarum.api.routes')]);