Revise session handling to prepare API authentication via token

This commit is contained in:
Bernd Bestel
2018-04-19 20:44:49 +02:00
parent 0c85342404
commit eae5b8bad9
9 changed files with 101 additions and 70 deletions

View File

@@ -6,7 +6,7 @@ class JsonMiddleware extends BaseMiddleware
{
public function __invoke(\Slim\Http\Request $request, \Slim\Http\Response $response, callable $next)
{
$response = $next($request, $response, $next);
$response = $next($request, $response);
return $response->withHeader('Content-Type', 'application/json');
}
}