Skip to content

Commit 56afe2d

Browse files
committed
Skip empty lines
1 parent 6f251a3 commit 56afe2d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lib/log.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@ Log.prototype = {
108108
this.stream.setEncoding('ascii');
109109
this.stream.on('data', function(chunk){
110110
chunk.split('\n').map(function(line){
111+
if (!line.length) return;
111112
var captures = line.match(/^\[([^\]]+)\] (\w+) (.*)/);
112113
var obj = {
113114
date: new Date(captures[1])

0 commit comments

Comments
 (0)