Refactor Classes

This commit is contained in:
2025-05-03 09:29:03 +02:00
parent 41a3c79c91
commit 6fa6b28af6
17 changed files with 125 additions and 151 deletions
@@ -13,7 +13,7 @@ class JsonBodyParserMiddleware implements MiddlewareInterface
{
$contentType = $request->getHeaderLine('Content-Type');
if (strstr($contentType, 'application/json')) {
if (str_contains($contentType, 'application/json')) {
$contents = json_decode(file_get_contents('php://input'), true);
if (json_last_error() === JSON_ERROR_NONE) {
$request = $request->withParsedBody($contents);