Skip to content

Commit f522174

Browse files
committed
Fix travis build by guarding against zero process.stdout.columns
1 parent 58475c3 commit f522174

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

lib/models/logger.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,9 @@ var Logger = CoreObject.extend({
1919
},
2020

2121
flush: function() {
22-
var maxWidth = process.stdout.columns - 4;
22+
// guard against environments such as travis that report zero columns
23+
var columns = process.stdout.columns || 80;
24+
var maxWidth = columns - 4;
2325
var halfWidth = Math.floor(maxWidth / 2);
2426
var table = new Table({
2527
head: ['Source', 'Destination'],

0 commit comments

Comments
 (0)