Skip to content

Commit d081554

Browse files
committed
fix mcp streamable http transport
1 parent ac9da06 commit d081554

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/MCP/StreamableHttpTransport.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ public function receive(): array
122122
}
123123

124124
try {
125-
return \json_decode($response, true, 512, \JSON_THROW_ON_ERROR);
125+
return \json_decode((string) $response, true, 512, \JSON_THROW_ON_ERROR);
126126
} catch (\JsonException $e) {
127127
// If the response from the server is not a valid JSON
128128
// try tp parse the SSE format to extract JSON data

0 commit comments

Comments
 (0)