From 8a7703b0ef2eff442647d1ab980f780ae346adc4 Mon Sep 17 00:00:00 2001 From: Bill Burke Date: Tue, 25 Oct 2016 20:41:18 -0400 Subject: [PATCH] fix link --- .../theme/base/admin/resources/js/controllers/users.js | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/themes/src/main/resources/theme/base/admin/resources/js/controllers/users.js b/themes/src/main/resources/theme/base/admin/resources/js/controllers/users.js index f1d20b1b15..1e7eb29c17 100755 --- a/themes/src/main/resources/theme/base/admin/resources/js/controllers/users.js +++ b/themes/src/main/resources/theme/base/admin/resources/js/controllers/users.js @@ -364,18 +364,15 @@ module.controller('UserDetailCtrl', function($scope, realm, user, BruteForceUser if(user.federationLink) { console.log("federationLink is not null"); if (user.federationLink.startsWith('f:')) { - var componentId = user.federationLink.substring(2); - var idx = componentId.indexOf(':'); - componentId = componentId.substring(idx); - Components.get({realm: realm.realm, componentId: componentId}, function (link) { + Components.get({realm: realm.realm, componentId: user.federationLink}, function (link) { $scope.federationLinkName = link.name; $scope.federationLink = "#/realms/" + realm.realm + "/user-storage/providers/" + link.providerId + "/" + link.id; - }) + }); } else { UserFederationInstances.get({realm: realm.realm, instance: user.federationLink}, function (link) { $scope.federationLinkName = link.displayName; $scope.federationLink = "#/realms/" + realm.realm + "/user-federation/providers/" + link.providerName + "/" + link.id; - }) + }); } } else {