From 3f6a7a4e5bd27fc4be70a1a63215ea97acaeb548 Mon Sep 17 00:00:00 2001 From: VLE2FE Date: Thu, 3 Sep 2020 16:34:50 +0200 Subject: [PATCH] small fixes --- src/helpers/mail.ts | 1 - src/routes/measurement.ts | 1 - src/routes/root.spec.ts | 1 - src/routes/sample.spec.ts | 1 - src/routes/sample.ts | 1 - src/routes/user.ts | 1 - 6 files changed, 6 deletions(-) diff --git a/src/helpers/mail.ts b/src/helpers/mail.ts index 2c0ab57..40326c3 100644 --- a/src/helpers/mail.ts +++ b/src/helpers/mail.ts @@ -50,7 +50,6 @@ export default class Mail{ }); }).then(() => { // init done successfully console.info('Mail service established successfully'); - this.send('lukas.veit@bosch.com', 'Mail Service started', new Date().toString()); }).catch(err => { // somewhere an error occurred console.error(`Mail init error: ${err.request.method} ${err.request.path}: ${err.response.status}`, err.response.data); diff --git a/src/routes/measurement.ts b/src/routes/measurement.ts index 73d7a87..701cf8a 100644 --- a/src/routes/measurement.ts +++ b/src/routes/measurement.ts @@ -176,7 +176,6 @@ async function templateCheck (measurement, param, res, next) { // validate values const {error, value} = ParametersValidate.input(measurement.values, templateData.parameters, 'null'); - console.log(error); if (error) {res400(error, res); return false;} return value || true; } diff --git a/src/routes/root.spec.ts b/src/routes/root.spec.ts index c0a7c26..337fc77 100644 --- a/src/routes/root.spec.ts +++ b/src/routes/root.spec.ts @@ -30,7 +30,6 @@ describe('/', () => { httpStatus: 200 }).end((err, res) => { if (err) return done(err); - console.log(res.body); should(res.body).have.lengthOf(2); should(res.body[0].date).be.eql('1979-07-28T06:04:51.000Z'); should(res.body[1].date).be.eql('1979-07-28T06:04:50.000Z'); diff --git a/src/routes/sample.spec.ts b/src/routes/sample.spec.ts index 9a53e29..9dec0fa 100644 --- a/src/routes/sample.spec.ts +++ b/src/routes/sample.spec.ts @@ -490,7 +490,6 @@ describe('/sample', () => { httpStatus: 200 }).end((err, res) => { if (err) return done(err); - console.log(res.body); const json = require('../test/db.json'); should(res.body).have.lengthOf(json.collections.samples.filter(e => e.status !== 'deleted').length); should(res.body).matchEach(sample => { diff --git a/src/routes/sample.ts b/src/routes/sample.ts index 71e84e9..cd97c01 100644 --- a/src/routes/sample.ts +++ b/src/routes/sample.ts @@ -652,7 +652,6 @@ router.post('/sample/new', async (req, res, next) => { sample.note_id = data._id; sample.user_id = req.authDetails.id; - console.log(sample); new SampleModel(sample).save((err, data) => { if (err) return next(err); db.log(req, 'samples', {_id: data._id}, data.toObject()); diff --git a/src/routes/user.ts b/src/routes/user.ts index c7cfb7f..7f5e791 100644 --- a/src/routes/user.ts +++ b/src/routes/user.ts @@ -134,7 +134,6 @@ router.post('/user/new', async (req, res, next) => { // validate input const {error, value: user} = UserValidate.input(req.body, 'new'); - console.log(error); if (error) return res400(error, res); // check that user does not already exist