
const { event } = require('../../../lib/db');

module.exports = async function (req, res, next) {

	try {
		const payload = req.body;

		await event.patch(req.params.project, req.params.id, payload, req.query);
		res.status(201).send();
		next();
	} catch (err) {
		next(err);
	}

};
