Skip to content

Commit

Permalink
[visualize spy] Pull index title instead of id (#13254)
Browse files Browse the repository at this point in the history
* [visualize spy] Pull index title instead of id

* [visualize spy] Check for existence of index before pulling params
  • Loading branch information
jbudz committed Aug 3, 2017
1 parent 78ac8e7 commit ba46cd4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/core_plugins/spy_modes/public/req_resp_stats_spy_mode.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ const linkReqRespStats = function ($scope) {
if (req && req.ms != null) stats.push(['Request Duration', req.ms + 'ms']);
if (resp && resp.hits) stats.push(['Hits', resp.hits.total]);

if (req.fetchParams) {
if (req.fetchParams.index) stats.push(['Index', req.fetchParams.index]);
if (req.fetchParams.type) stats.push(['Type', req.fetchParams.type]);
if (req.fetchParams.id) stats.push(['Id', req.fetchParams.id]);
if (req.fetchParams && req.fetchParams.index) {
if (req.fetchParams.index.title) stats.push(['Index', req.fetchParams.index.title]);
if (req.fetchParams.index.type) stats.push(['Type', req.fetchParams.index.type]);
if (req.fetchParams.index.id) stats.push(['Id', req.fetchParams.index.id]);
}
});
};
Expand Down

0 comments on commit ba46cd4

Please sign in to comment.