checksum fail message undefined, app.use() duplicate

This commit is contained in:
Omar Brikaa 2022-01-22 18:56:33 +02:00
parent 20e71f617b
commit 3372ca1954
2 changed files with 3 additions and 2 deletions

View File

@ -77,7 +77,6 @@ expressWs(app);
const api_v2 = require('./api/v2'); const api_v2 = require('./api/v2');
app.use('/api/v2', api_v2); app.use('/api/v2', api_v2);
app.use('/api/v2', api_v2);
app.use((req, res, next) => { app.use((req, res, next) => {
return res.status(404).send({ message: 'Not Found' }); return res.status(404).send({ message: 'Not Found' });

View File

@ -80,7 +80,9 @@ class Package {
const cs = hash.digest('hex'); const cs = hash.digest('hex');
if (cs !== this.checksum) { if (cs !== this.checksum) {
throw new Error(`Checksum miss-match want: ${val} got: ${cs}`); throw new Error(
`Checksum miss-match want: ${this.checksum} got: ${cs}`
);
} }
logger.debug( logger.debug(