Open finnhodgkin opened 6 years ago
In handleCreateUser you're repeatedly calling qs.parse on the same data, this only needs to be done once:
const parsedDetails = qs.parse(data); const pass = parsedDetails.pass; const user = parsedDetails.user; const first = parsedDetails.first; const last = parsedDetails.last; const address = parsedDetails.address;
Or in one line:
const {pass, user, first, last, address} = qs.parse(data);
In handleCreateUser you're repeatedly calling qs.parse on the same data, this only needs to be done once:
Or in one line: