diff --git a/src/Runtime/LambdaRuntime.php b/src/Runtime/LambdaRuntime.php index dbf1f68dd..a42e28b5b 100755 --- a/src/Runtime/LambdaRuntime.php +++ b/src/Runtime/LambdaRuntime.php @@ -244,7 +244,7 @@ public function failInitialization(string $message, ?\Throwable $error = null): private function postJson(string $url, $data): void { $contentType = $data['multiValueHeaders']['content-type'][0] ?? null; - if ($contentType && $contentType !== 'application/json' && substr($contentType, 0, 4) !== 'text') { + if ($contentType && $contentType !== 'application/json' && substr($contentType, 0, 5) !== 'text/') { $data['body'] = base64_encode($data['body']); $data['isBase64Encoded'] = true; }