From b5071d504fbe77fc02c0a17be45f153552086f5c Mon Sep 17 00:00:00 2001 From: barisusakli Date: Mon, 9 Jun 2014 02:33:07 -0400 Subject: [PATCH] removed timing #1654 --- src/routes/api.js | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/routes/api.js b/src/routes/api.js index 0115249d75..5f7ef811cd 100644 --- a/src/routes/api.js +++ b/src/routes/api.js @@ -137,11 +137,9 @@ function getModerators(req, res, next) { var templatsListingCache = []; function getTemplatesListing(req, res, next) { - var st = process.hrtime(); - //if (templatsListingCache.length) { - // process.profile('with cache', st); -// return res.json(templatsListingCache); -// } + if (templatsListingCache.length) { + return res.json(templatsListingCache); + } async.parallel({ views: function(next) { @@ -163,7 +161,6 @@ function getTemplatesListing(req, res, next) { data = data.concat(results.extended); templatsListingCache = data; - process.profile('without cache', st); res.json(data); }); }