Unverified Commit 49783b90 authored by Aaron Ogle's avatar Aaron Ogle Committed by GitHub

Merge pull request #87 from RocketChat/require-changes

Require Change Information When Submitting Updates
parents c4e7021f 4f5fa4c9
......@@ -97,7 +97,16 @@ export default class Submit extends Command {
flags.update = !(isNewApp as any).isNew;
}
if (!flags.update) {
let changes = '';
if (flags.update) {
const result: any = await inquirer.prompt([{
type: 'input',
name: 'changes',
message: 'What changes were made in this version?',
}]);
changes = result.changes;
} else {
const isFreeQuestion: any = await inquirer.prompt([{
type: 'confirm',
name: 'isFree',
......@@ -167,6 +176,10 @@ export default class Submit extends Command {
data.append('app', fs.createReadStream(fd.mergeWithFolder(zipName)));
data.append('categories', JSON.stringify(selectedCategories));
if (changes) {
data.append('changes', changes);
}
const token = await cloudAuth.getToken();
await this.asyncSubmitData(data, flags, fd, token);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment