MCPcopy Create free account
hub / github.com/dataease/SQLBot / toPost

Function toPost

g2-ssr/app.js:71–80  ·  view source on GitHub ↗
(req, res)

Source from the content-addressed store, hash-verified

69
70//获取POST请求内容、cookie
71function toPost(req, res) {
72 const bodyChunks = []
73 req.on('data', function (chunk) {
74 bodyChunks.push(chunk)
75 }).on('end', async () => {
76 const completeBodyBuffer = Buffer.concat(bodyChunks);
77 await GenerateCharts(JSON.parse(completeBodyBuffer.toString('utf8')))
78 res.end('complete');
79 });
80}

Callers 1

app.jsFile · 0.85

Calls 6

GenerateChartsFunction · 0.85
concatMethod · 0.80
onMethod · 0.65
pushMethod · 0.45
parseMethod · 0.45
toStringMethod · 0.45

Tested by

no test coverage detected