diff --git a/src/views/profile.html b/src/views/profile.html
index 5f73426ba..1fa778343 100644
--- a/src/views/profile.html
+++ b/src/views/profile.html
@@ -295,13 +295,8 @@
-
You have {{ activeClients.length + 1 }} active session(s), including this one.
-
-
- Active Sessions:
- {{ client.name }} - {{client.activeTokens.length}} time(s)
-
-
+
You have {{ webadminClient.activeTokens.length }} active web session(s) and {{ cliClient.activeTokens.length }} CLI token(s).
+
diff --git a/src/views/profile.js b/src/views/profile.js
index 8895988aa..a9384f014 100644
--- a/src/views/profile.js
+++ b/src/views/profile.js
@@ -8,10 +8,10 @@ angular.module('Application').controller('ProfileController', ['$scope', '$locat
$scope.user = Client.getUserInfo();
$scope.config = Client.getConfig();
- $scope.activeTokens = 0;
$scope.activeClients = [];
$scope.webadminClient = {};
$scope.apiClient = {};
+ $scope.cliClient = {};
$scope.showApiTokens = !!$location.search().tokens;
$scope.twoFactorAuthentication = {
@@ -391,13 +391,9 @@ angular.module('Application').controller('ProfileController', ['$scope', '$locat
asyncForEach(activeClients, refreshClientTokens, function () {
$scope.webadminClient = activeClients.filter(function (c) { return c.id === 'cid-webadmin'; })[0];
$scope.apiClient = activeClients.filter(function (c) { return c.id === 'cid-sdk'; })[0];
+ $scope.cliClient = activeClients.filter(function (c) { return c.id === 'cid-cli'; })[0];
- activeClients = activeClients.filter(function (c) { return c.activeTokens.length > 0; });
-
- $scope.activeClients = activeClients.filter(function (c) { return c.id !== 'cid-sdk' && c.id !== 'cid-webadmin'; });
-
- $scope.activeTokenCount = $scope.activeClients.reduce(function (prev, cur) { return prev + cur.activeTokens.length; }, 0);
- $scope.activeTokenCount += $scope.webadminClient ? $scope.webadminClient.activeTokens.length : 0;
+ $scope.activeClients = activeClients;
});
});
});