diff --git a/examples/http_server.rb b/examples/http_server.rb index 1f5abac..811775c 100644 --- a/examples/http_server.rb +++ b/examples/http_server.rb @@ -125,7 +125,7 @@ app = proc do |env| # Log the MCP response details _, _, body = response - if body.is_a?(Array) && !body.empty? + if body.is_a?(Array) && !body.empty? && body.first begin parsed_response = JSON.parse(body.first) if parsed_response["error"]