fix(core): update
This commit is contained in:
parent
6f5d10ccd3
commit
7a3e565dbb
@ -14,11 +14,11 @@ const buildUtf8Response = (
|
||||
const done = plugins.smartpromise.defer<IExtendedIncomingMessage>();
|
||||
// Continuously update stream with data
|
||||
let body = '';
|
||||
incomingMessageArg.on('data', function(chunkArg) {
|
||||
incomingMessageArg.on('data', (chunkArg) => {
|
||||
body += chunkArg;
|
||||
});
|
||||
|
||||
incomingMessageArg.on('end', function() {
|
||||
incomingMessageArg.on('end', () => {
|
||||
if (autoJsonParse) {
|
||||
try {
|
||||
(incomingMessageArg as IExtendedIncomingMessage).body = JSON.parse(body);
|
||||
|
Loading…
Reference in New Issue
Block a user