Skip to content

Commit

Permalink
job.js add status prop for email
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeTWC1984 authored Aug 19, 2020
1 parent 8cd005d commit b889a35
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/job.js
Original file line number Diff line number Diff line change
Expand Up @@ -1340,6 +1340,9 @@ module.exports = Class.create({
email_data.notes = (data.notes || '(None)').trim();
email_data.nice_log_size = Tools.getTextFromBytes( data.log_file_size || 0 );
email_data.pid = data.pid || '(Unknown)';
email_data.status = "Success";
if(job.code > 0) {email_data.status = "Error"};
if(job.code == 255) {email_data.status = "Warning"};

// compose nice mem/cpu usage info
email_data.nice_mem = '(Unknown)';
Expand Down

0 comments on commit b889a35

Please sign in to comment.