From c33527ff632817e589a3830a6fdf57d84a330fd6 Mon Sep 17 00:00:00 2001 From: Stephen Cavaliere Date: Fri, 3 Mar 2017 21:42:25 -0500 Subject: [PATCH] fix(@angular/cli): fix issue with console prompt bailing early fixes #5127, #4614 --- packages/@angular/cli/ember-cli/lib/ui/index.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/packages/@angular/cli/ember-cli/lib/ui/index.js b/packages/@angular/cli/ember-cli/lib/ui/index.js index 7837f04e0f52..3e749d1a0166 100644 --- a/packages/@angular/cli/ember-cli/lib/ui/index.js +++ b/packages/@angular/cli/ember-cli/lib/ui/index.js @@ -174,12 +174,10 @@ UI.prototype.prompt = function(questions, callback) { // If no callback was provided, automatically return a promise if (callback) { - inquirer.prompt(questions, callback); - } else { - return new Promise(function(resolve) { - inquirer.prompt(questions, resolve); - }); + return inquirer.prompt(questions, callback); } + + return inquirer.prompt(questions); }; /**