Skip to content

Commit f2d04ca

Browse files
committed
#141: log all clarify calls, including failed ones
1 parent 0746042 commit f2d04ca

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

core/middlewares/clarify.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,11 @@ module.exports.process = function(req, res, next) {
252252
var specID = specUtils.getSpecIDFromUrl(parsedPath.pathToSpec);
253253
var specHasHTMLAPIData = !!parseHTMLData.getByID(specID);
254254

255+
trackStats.page({
256+
pageName: 'clarify',
257+
sessionID: trackStats.getSessionID(req)
258+
});
259+
255260
if (!specInfo) {
256261
res.send('Clarify did not found any information about requested spec, please check URL or update file-tree restarting the app.');
257262
return;
@@ -314,11 +319,6 @@ module.exports.process = function(req, res, next) {
314319
html = msg;
315320
}
316321

317-
trackStats.page({
318-
pageName: 'clarify',
319-
sessionID: trackStats.getSessionID(req)
320-
});
321-
322322
res.send(html);
323323
}).fail(function(err) {
324324
var msg = 'ERROR: Could not find requested or default template for Clarify';

0 commit comments

Comments
 (0)