diff --git a/commands/record.js b/commands/record.js index 70cf822..1309ebf 100644 --- a/commands/record.js +++ b/commands/record.js @@ -137,10 +137,13 @@ function done() { // Store the data into the recording file try { + di.fs.writeFileSync(recordingFile, outputYAML, 'utf8'); + } catch (error) { - di.errorHandler(error.message); - process.exit(); + + return di.errorHandler(error); + } console.log(di.chalk.green('Successfully Recorded'));