Skip to content

Commit

Permalink
Fix react-native-cli code formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
frantic committed May 18, 2015
1 parent f2b7656 commit 214ae20
Showing 1 changed file with 18 additions and 18 deletions.
36 changes: 18 additions & 18 deletions react-native-cli/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,24 +78,24 @@ function init(name) {
}

function createAfterConfirmation(name) {
prompt.start();

var property = {
name: 'yesno',
message: 'Directory ' + name + ' already exist. Continue?',
validator: /y[es]*|n[o]?/,
warning: 'Must respond yes or no',
default: 'no'
};

prompt.get(property, function (err, result) {
if (result.yesno[0] === 'y') {
createProject(name);
} else {
console.log('Project initialization canceled');
process.exit();
}
});
prompt.start();

var property = {
name: 'yesno',
message: 'Directory ' + name + ' already exist. Continue?',
validator: /y[es]*|n[o]?/,
warning: 'Must respond yes or no',
default: 'no'
};

prompt.get(property, function (err, result) {
if (result.yesno[0] === 'y') {
createProject(name);
} else {
console.log('Project initialization canceled');
process.exit();
}
});
}

function createProject(name) {
Expand Down

0 comments on commit 214ae20

Please sign in to comment.