accept posted urls
This commit is contained in:
parent
060c10b5ab
commit
c0bc6df3e7
@ -625,6 +625,19 @@ router.get('/new', function (req, res) {
|
||||
|
||||
});
|
||||
|
||||
router.post('/new', function (req, res) {
|
||||
logger.debug('Posted Save new');
|
||||
logger.info( req.body);
|
||||
if (Object.keys(req.body).length !== 0)
|
||||
{
|
||||
busEmitter.emit("getBookmarkRes", req.body.url, res);
|
||||
}
|
||||
else {
|
||||
res.status(422).end();
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
busEmitter.emit('updateTagsDB');
|
||||
|
||||
module.exports = router;
|
||||
|
Loading…
Reference in New Issue
Block a user