Skip to content

Commit

Permalink
Only the email is actually needed, so don't ask for id, name, or slug
Browse files Browse the repository at this point in the history
  • Loading branch information
PaulAdamDavis committed Jan 8, 2025
1 parent 9eb73b2 commit 705167b
Showing 1 changed file with 0 additions and 48 deletions.
48 changes: 0 additions & 48 deletions tasks/json-clean.js
Original file line number Diff line number Diff line change
Expand Up @@ -234,51 +234,6 @@ const getFullTaskList = (options) => {
let theData = _.clone(user.originalData);

const promptOptions = [
{
type: 'input',
name: 'userID',
message: 'The new ID:',
filter: function (val) {
return val.trim();
},
validate: (input) => {
if (input.length) {
return true;
} else {
return 'Please provide an ID';
}
}
},
{
type: 'input',
name: 'userName',
message: 'The new name:',
filter: function (val) {
return val.trim();
},
validate: (input) => {
if (input.length) {
return true;
} else {
return 'Please provide a name';
}
}
},
{
type: 'input',
name: 'userSlug',
message: 'The new slug:',
filter: function (val) {
return val.trim();
},
validate: (input) => {
if (input.length) {
return true;
} else {
return 'Please provide a slug';
}
}
},
{
type: 'input',
name: 'userEmail',
Expand All @@ -298,9 +253,6 @@ const getFullTaskList = (options) => {

await inquirer.prompt(promptOptions).then(async (answers) => {
// Prompt for updates to these values
theData.id = answers.userID; // Something new
theData.name = answers.userName; // Something new
theData.slug = answers.userSlug; // Something new
theData.email = answers.userEmail; // Something new

// Add the new data to the user object
Expand Down

0 comments on commit 705167b

Please sign in to comment.