Archived
2

Merge pull request #45 in ~VLE2FE/definma-api from develop to master

* commit '3f6a7a4e5bd27fc4be70a1a63215ea97acaeb548':
  small fixes
This commit is contained in:
Veit Lukas (PEA4-Fe) 2020-09-03 16:35:18 +02:00
commit d0c3a2981c
6 changed files with 0 additions and 6 deletions

View File

@ -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);

View File

@ -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;
}

View File

@ -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');

View File

@ -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 => {

View File

@ -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());

View File

@ -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