Compile with new changes

This commit is contained in:
Matt McWilliams 2023-06-30 10:46:15 -04:00
parent 522ad74717
commit 7f9ad68cce
1 changed files with 2 additions and 2 deletions

4
dist/index.js vendored
View File

@ -218,7 +218,7 @@ app.post('/', uploadZip.single('dataset'), async (req, res, next) => {
let fileExists; let fileExists;
let id; let id;
req.setTimeout(0); req.setTimeout(0);
if (typeof req.file === 'undefined' && req.file === null) { if (typeof req.file === 'undefined' || req.file === null) {
console.error('No file in upload'); console.error('No file in upload');
return next('ERROR: Please upload dataset as zip file'); return next('ERROR: Please upload dataset as zip file');
} }
@ -269,7 +269,7 @@ app.post('/job/:id', uploadOnnx.single('model'), async (req, res, next) => {
let meta = null; let meta = null;
let id; let id;
req.setTimeout(0); req.setTimeout(0);
if (typeof req.file === 'undefined' && req.file === null) { if (typeof req.file === 'undefined' || req.file === null) {
console.error('No file in upload'); console.error('No file in upload');
return next('ERROR: Please model as ONNX file'); return next('ERROR: Please model as ONNX file');
} }