Skip to content
This repository has been archived by the owner on Feb 23, 2021. It is now read-only.

Don't log if no metric property id is set. #166

Merged
merged 1 commit into from Sep 13, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion command/CommandController.js
Expand Up @@ -301,8 +301,8 @@ router.get('/search', VerifyToken, async function(req, res) {
});

function logMetric(cmd, userid, agent) {
logger.info('User-Agent is: ' + agent);
if (process.env.GA_PROPERTY_ID) {
logger.info('User-Agent is: ' + agent);
var visitor = ua(process.env.GA_PROPERTY_ID, userid);
var ga_params = {
ec: cmd,
Expand Down