From 39886c854519211d047293d18d58384ee41f4fd7 Mon Sep 17 00:00:00 2001 From: barisusakli Date: Sun, 15 Jun 2014 21:08:43 -0400 Subject: [PATCH] removed unread total route --- src/controllers/categories.js | 2 +- src/routes/index.js | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/controllers/categories.js b/src/controllers/categories.js index c51cc33b4c..b066d4c8e4 100644 --- a/src/controllers/categories.js +++ b/src/controllers/categories.js @@ -56,7 +56,7 @@ categoriesController.unreadTotal = function(req, res, next) { return next(err); } - res.render('unread', data); + res.json(data); }); }; diff --git a/src/routes/index.js b/src/routes/index.js index eaab5ff63c..184a658e81 100644 --- a/src/routes/index.js +++ b/src/routes/index.js @@ -77,7 +77,6 @@ function categoryRoutes(app, middleware, controllers) { app.get('/unread/', middleware.buildHeader, middleware.authenticate, controllers.categories.unread); app.get('/api/unread/', middleware.authenticate, controllers.categories.unread); - app.get('/unread/total', middleware.buildHeader, middleware.authenticate, controllers.categories.unreadTotal); app.get('/api/unread/total', middleware.authenticate, controllers.categories.unreadTotal); app.get('/category/:category_id/:slug?', middleware.buildHeader, middleware.addSlug, controllers.categories.get);