Archived
2

Extract data from request

This commit is contained in:
Ruben Hartenstein (PEA4-Fe) 2021-03-09 17:01:24 +01:00
parent 7afca52309
commit 4dc4c85fb9

View File

@ -126,6 +126,11 @@ router.post('/measurement/new', async (req, res, next) => {
});
});
router.post('/measurement/new/raspi', (req, res) => {
if (!req.auth(res, Object.values(globals.levels))) return;
// Needed data to rebuild measurement structure
JSON.parse(String.fromCodePoint(...req._readableState.buffer.head.data)).value;
});
module.exports = router;