Skip to content
This repository was archived by the owner on Oct 23, 2018. It is now read-only.

Commit 6e080f5

Browse files
committed
Fix failure when item.msg is array
1 parent 7faac4b commit 6e080f5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: lib/formatter.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ var cwd = process.cwd();
1212
*/
1313
var formatRow = function(item) {
1414
// Drop newline symbol in error string
15-
item.msg = item.msg.replace('\n', '');
15+
item.msg = (Array.isArray(item.msg) ? item.msg.join(' ') : item.msg).replace('\n', '');
1616
// Using zero instead of undefined
1717
item.column = (item.column === undefined) ? 0 : item.column;
1818
// Drop `PUG:LINT_` prefix in error code

0 commit comments

Comments
 (0)