#101 Fix a crash in bunyan
rendering a record with unexpected "res.headers".
This commit is contained in:
parent
06ade787dc
commit
89d5326c7f
2 changed files with 7 additions and 6 deletions
11
CHANGES.md
11
CHANGES.md
|
@ -8,20 +8,19 @@ Known issues:
|
||||||
|
|
||||||
## bunyan 0.22.1 (not yet released)
|
## bunyan 0.22.1 (not yet released)
|
||||||
|
|
||||||
(nothing yet)
|
- #101 Fix a crash in `bunyan` rendering a record with unexpected "res.headers".s
|
||||||
|
|
||||||
|
|
||||||
## bunyan 0.22.0
|
## bunyan 0.22.0
|
||||||
|
|
||||||
- [issue #104] `log.reopenFileStreams()` convenience method to be used with
|
- #104 `log.reopenFileStreams()` convenience method to be used with external log
|
||||||
external log rotation.
|
rotation.
|
||||||
|
|
||||||
|
|
||||||
## bunyan 0.21.4
|
## bunyan 0.21.4
|
||||||
|
|
||||||
- [issue #96] Fix `bunyan` to default to paging (with `less`) by default in
|
- #96 Fix `bunyan` to default to paging (with `less`) by default in node 0.10.0.
|
||||||
node 0.10.0. The intention has always been to default to paging for node
|
The intention has always been to default to paging for node >=0.8.
|
||||||
>=0.8.
|
|
||||||
|
|
||||||
|
|
||||||
## bunyan 0.21.3
|
## bunyan 0.21.3
|
||||||
|
|
|
@ -834,6 +834,8 @@ function emitRecord(rec, line, opts, stylize) {
|
||||||
var s = '';
|
var s = '';
|
||||||
if (res.header) {
|
if (res.header) {
|
||||||
s += res.header.trimRight();
|
s += res.header.trimRight();
|
||||||
|
} else if (typeof(res.headers) === 'string') {
|
||||||
|
s += res.headers.trimRight();
|
||||||
} else if (res.headers) {
|
} else if (res.headers) {
|
||||||
if (res.statusCode) {
|
if (res.statusCode) {
|
||||||
s += format('HTTP/1.1 %s %s\n', res.statusCode,
|
s += format('HTTP/1.1 %s %s\n', res.statusCode,
|
||||||
|
|
Loading…
Reference in a new issue