mirror of
https://github.com/nttgin/BGPalerter.git
synced 2024-05-19 06:50:08 +00:00
redirected logs to files
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
import Report from "./report";
|
||||
import nodemailer from "nodemailer";
|
||||
import logger from '../logger';
|
||||
|
||||
|
||||
export default class ReportEmail extends Report {
|
||||
|
||||
@@ -30,7 +32,10 @@ export default class ReportEmail extends Report {
|
||||
text: "Hello world?"
|
||||
})
|
||||
.catch(error => {
|
||||
console.log("log the error properly!", error);
|
||||
logger.log({
|
||||
level: 'error',
|
||||
message: error
|
||||
});
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user