From f5fbd2888d61542dd75417eb87251c08a75b20a4 Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Fri, 18 Mar 2016 01:52:23 +0300 Subject: [PATCH] - /news/:id router --- src/routes/news.js | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/src/routes/news.js b/src/routes/news.js index d5cd879b..6315573d 100644 --- a/src/routes/news.js +++ b/src/routes/news.js @@ -64,17 +64,4 @@ export default function (app) { .then(i => i.sort(sortNewsByDate)); } }))); - - app.use(route.get('/news/:id', accepts({ - 'text/html': index(), - 'text/plain': index(), - 'application/json': function *(id) { - let item = yield c('timeline').findOne({uri: id}); - if (item) { - this.body = item; - } else { - this.status = 404; - } - } - }))); };