Commit fbb89236 authored by George Goldberg's avatar George Goldberg Committed by JoramWilander

MM-13062: Fix missed out diagnostic action. (#2184)

parent 0e3bef33
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import {Client4} from 'mattermost-redux/client';
import {getConfig} from 'mattermost-redux/selectors/entities/general';
import {getCurrentUserId} from 'mattermost-redux/selectors/entities/users';
import store from 'stores/redux_store.jsx';
......@@ -16,23 +16,7 @@ const SUPPORTS_MEASURE_METHODS = isSupported([
]);
export function trackEvent(category, event, props) {
if (global.window && global.window.analytics) {
const properties = Object.assign({category, type: event, user_actual_id: getCurrentUserId(store.getState())}, props);
const options = {
context: {
ip: '0.0.0.0',
},
page: {
path: '',
referrer: '',
search: '',
title: '',
url: '',
},
anonymousId: '00000000000000000000000000',
};
global.window.analytics.track('event', properties, options);
}
Client4.trackEvent(category, event, props);
}
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment