Skip to content

Commit 16a383f

Browse files
authored
Remove the confirm step when removing a session (#18)
1 parent 8cf39b5 commit 16a383f

File tree

1 file changed

+1
-18
lines changed

1 file changed

+1
-18
lines changed

lib/commands/session.js

+1-18
Original file line numberDiff line numberDiff line change
@@ -99,24 +99,7 @@ cmd.handler = function(argv) {
9999
}
100100

101101
if (argv.delete) {
102-
log.info([
103-
chalk.red.bold('CAREFUL! This action CANNOT be undone!'),
104-
'\nThis will permanently delete all your submissions',
105-
'and progress associated with this session.',
106-
'\nAre you sure you want to delete this session?\n',
107-
'\nPlease type in the session\'s',
108-
chalk.yellow.bold('number of accepted submissions'),
109-
'to confirm.\n'
110-
].join(' '));
111-
112-
prompt.colors = false;
113-
prompt.message = '';
114-
prompt.start();
115-
prompt.get([{name: 'answer', type: 'integer', required: true}], function(e, x) {
116-
if (x.answer !== session.total_acs) return;
117-
return core.deleteSession(session, printSessions);
118-
});
119-
return;
102+
return core.deleteSession(session, printSessions);
120103
}
121104
}
122105
printSessions(null, sessions);

0 commit comments

Comments
 (0)