Code example:
void foo(HTTPServerRequest req, HTTPServerResponse res)
{
string str = `[1,2,3]`;
res.statusCode = HTTPStatus.OK;
res.headers["Content-Type"] = "application/json; charset=UTF-8";
res.bodyWriter.write(str);
res.bodyWriter.flush();
}
Do I need to call res.bodyWriter.flush
explicitly?