diff --git a/framework/core/src/Admin/Server.php b/framework/core/src/Admin/Server.php index 022924060..1047d8923 100644 --- a/framework/core/src/Admin/Server.php +++ b/framework/core/src/Admin/Server.php @@ -32,7 +32,7 @@ class Server extends AbstractServer if ($app->isUpToDate()) { $pipe->pipe($adminPath, $app->make('Flarum\Http\Middleware\ParseJsonBody')); - $pipe->pipe($adminPath, $app->make('Flarum\Http\Middleware\AuthorizeWithCookie')); + $pipe->pipe($adminPath, $app->make('Flarum\Http\Middleware\AuthenticateWithCookie')); $pipe->pipe($adminPath, $app->make('Flarum\Http\Middleware\StartSession')); $pipe->pipe($adminPath, $app->make('Flarum\Http\Middleware\SetLocale')); $pipe->pipe($adminPath, $app->make('Flarum\Admin\Middleware\RequireAdministrateAbility')); diff --git a/framework/core/src/Api/Server.php b/framework/core/src/Api/Server.php index 56371d50f..ab518cd86 100644 --- a/framework/core/src/Api/Server.php +++ b/framework/core/src/Api/Server.php @@ -30,8 +30,8 @@ class Server extends AbstractServer if ($app->isInstalled() && $app->isUpToDate()) { $pipe->pipe($apiPath, $app->make('Flarum\Http\Middleware\ParseJsonBody')); $pipe->pipe($apiPath, $app->make('Flarum\Api\Middleware\FakeHttpMethods')); - $pipe->pipe($apiPath, $app->make('Flarum\Http\Middleware\AuthorizeWithCookie')); - $pipe->pipe($apiPath, $app->make('Flarum\Http\Middleware\AuthorizeWithHeader')); + $pipe->pipe($apiPath, $app->make('Flarum\Http\Middleware\AuthenticateWithCookie')); + $pipe->pipe($apiPath, $app->make('Flarum\Http\Middleware\AuthenticateWithHeader')); $pipe->pipe($apiPath, $app->make('Flarum\Http\Middleware\StartSession')); $pipe->pipe($apiPath, $app->make('Flarum\Http\Middleware\SetLocale')); $pipe->pipe($apiPath, $app->make('Flarum\Http\Middleware\DispatchRoute', ['routes' => $app->make('flarum.api.routes')])); diff --git a/framework/core/src/Forum/Server.php b/framework/core/src/Forum/Server.php index a6dc97069..18df07f7b 100644 --- a/framework/core/src/Forum/Server.php +++ b/framework/core/src/Forum/Server.php @@ -36,7 +36,7 @@ class Server extends AbstractServer $pipe->pipe($basePath, new HandleErrors($errorDir, true)); } elseif ($app->isUpToDate()) { $pipe->pipe($basePath, $app->make('Flarum\Http\Middleware\ParseJsonBody')); - $pipe->pipe($basePath, $app->make('Flarum\Http\Middleware\AuthorizeWithCookie')); + $pipe->pipe($basePath, $app->make('Flarum\Http\Middleware\AuthenticateWithCookie')); $pipe->pipe($basePath, $app->make('Flarum\Http\Middleware\StartSession')); $pipe->pipe($basePath, $app->make('Flarum\Http\Middleware\SetLocale')); $pipe->pipe($basePath, $app->make('Flarum\Http\Middleware\DispatchRoute', ['routes' => $app->make('flarum.forum.routes')]));