Skip to content

Commit 4142ca9

Browse files
bjdelroSBoudrias
authored andcommittedDec 9, 2017
Fixes ParseError (#554)
1 parent 035faf7 commit 4142ca9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed
 

‎lib/routes/home.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ const _ = require('lodash');
33
const chalk = require('chalk');
44
const fullname = require('fullname');
55
const inquirer = require('inquirer');
6+
const isString = require('lodash').isString;
67
const namespaceToName = require('yeoman-environment').namespaceToName;
78
const globalConfigHasContent = require('../utils/global-config').hasContent;
89

@@ -54,7 +55,7 @@ module.exports = app => {
5455
app.insight.track('yoyo', 'home');
5556

5657
return fullname().then(name => {
57-
const allo = name ? `'Allo ${name.split(' ')[0]}! ` : '\'Allo! ';
58+
const allo = (name && isString(name)) ? `'Allo ${name.split(' ')[0]}! ` : '\'Allo! ';
5859

5960
return inquirer.prompt([{
6061
name: 'whatNext',

0 commit comments

Comments
 (0)
Please sign in to comment.