src/index.js
function getBody(req) {
  return new Promise((resolve, reject) => {
    let data = '';
    req
      .on('data', (chunk) => {
        data += chunk;
      })
      .on('end', () => {
        resolve(data);
      })
      .on('error', reject);
  });
}
function getBody(req) {
  return new Promise((resolve, reject) => {
    let data = '';
    req
      .on('data', (chunk) => {
        data += chunk;
      })
      .on('end', () => {
        resolve(data);
      })
      .on('error', reject);
  });
}
function getBody ( req ) { return new Promise ( ( resolve , reject ) => { let data = '' ; req . on ( 'data' , ( chunk ) => { data += chunk ; } ) . on ( 'end' , ( ) => { resolve ( data ) ; } ) . on ( 'error' , reject ) ; } ) ; }
import querystring from 'querystring';
import querystring from querystring ;