Comparing version 0.11.6 to 0.11.7
@@ -8,2 +8,7 @@ # Nodecaf Changelog | ||
## [v0.11.7] - 2021-05-03 | ||
### Fixed | ||
- crash when client aborts request while sending body | ||
## [v0.11.6] - 2021-05-03 | ||
@@ -496,1 +501,2 @@ | ||
[v0.11.6]: https://gitlab.com/GCSBOSS/nodecaf/-/tags/v0.11.6 | ||
[v0.11.7]: https://gitlab.com/GCSBOSS/nodecaf/-/tags/v0.11.7 |
@@ -37,7 +37,11 @@ | ||
this.req.on('aborted', () => | ||
!this.complete && this.req.emit('error', new Error('Request was aborted'))); | ||
return new Promise((resolve, reject) => { | ||
this.req.on('aborted', () => { | ||
this.log.warn({ req: this.req, type: 'request' }, | ||
'Client aborted while sending request body'); | ||
!this.complete && reject(err); | ||
this.complete = true; | ||
}); | ||
this.req.on('end', () => { | ||
@@ -44,0 +48,0 @@ !this.complete && resolve(Buffer.concat(buffer)); |
{ | ||
"name": "nodecaf", | ||
"version": "0.11.6", | ||
"version": "0.11.7", | ||
"description": "Nodecaf is a light framework for developing RESTful Apps in a quick and convenient manner.", | ||
@@ -5,0 +5,0 @@ "main": "lib/main.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
56101
612