diff --git a/restapi/index.php b/restapi/index.php index 75f027863..5e0d8ba61 100644 --- a/restapi/index.php +++ b/restapi/index.php @@ -3174,6 +3174,11 @@ $app->addErrorMiddleware(true, true, true); $app->add(new RestapiCorsMiddleware($container)); +/* Without the BodyParsingMiddleware the body of PUT Request will + * not be parsed in Slim4 + */ +$app->addBodyParsingMiddleware(); + // Make CORS preflighted request possible $app->options('/{routes:.+}', function ($request, $response, $args) { return $response;