Skip to content

Commit

Permalink
Use const/let in spyModes plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
epixa committed Feb 2, 2016
1 parent bd1e23b commit 4a0396c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
12 changes: 6 additions & 6 deletions src/plugins/spyModes/public/reqRespStatsSpyMode.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
define(function (require) {
var _ = require('lodash');
var reqRespStatsHTML = require('plugins/spyModes/reqRespStatsSpyMode.html');
const _ = require('lodash');
const reqRespStatsHTML = require('plugins/spyModes/reqRespStatsSpyMode.html');

var linkReqRespStats = function ($scope, config) {
const linkReqRespStats = function ($scope, config) {
$scope.$bind('req', 'searchSource.history[searchSource.history.length - 1]');
$scope.$watchMulti([
'req',
Expand All @@ -12,9 +12,9 @@ define(function (require) {
], function () {
if (!$scope.searchSource || !$scope.req) return;

var req = $scope.req;
var resp = $scope.req.resp;
var stats = $scope.stats = [];
const req = $scope.req;
const resp = $scope.req.resp;
const stats = $scope.stats = [];

if (resp && resp.took != null) stats.push(['Query Duration', resp.took + 'ms']);
if (req && req.ms != null) stats.push(['Request Duration', req.ms + 'ms']);
Expand Down
8 changes: 4 additions & 4 deletions src/plugins/spyModes/public/tableSpyMode.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
define(function (require) {
function VisSpyTableProvider(Notifier, $filter, $rootScope, config, Private) {
var _ = require('lodash');
var saveAs = require('@spalger/filesaver').saveAs;
var tabifyAggResponse = Private(require('ui/agg_response/tabify/tabify'));
const _ = require('lodash');
const saveAs = require('@spalger/filesaver').saveAs;
const tabifyAggResponse = Private(require('ui/agg_response/tabify/tabify'));

var PER_PAGE_DEFAULT = 10;
const PER_PAGE_DEFAULT = 10;

require('ui/agg_table');

Expand Down

0 comments on commit 4a0396c

Please sign in to comment.