-apiDelete('/feeds/:feed_id',{auth: true}, async (req, res) => {
- const id = req.params.feed_id;
+apiDelete('/accounts/:account_id/feeds/:feed_id',{auth: true}, async (req, res) => {
+ const { feed_id, account_id } = req.params;
+ if(!query.isFeedOwnedBy(account_id, feed_id)) {
+ throw new Error('Invalid feed');
+ }