diff --git a/awx/ui/client/src/controllers/Credentials.js b/awx/ui/client/src/controllers/Credentials.js index 5af27f9f65..7b9a75acd8 100644 --- a/awx/ui/client/src/controllers/Credentials.js +++ b/awx/ui/client/src/controllers/Credentials.js @@ -182,6 +182,8 @@ export function CredentialsAdd($scope, $rootScope, $compile, $location, $log, Rest.get() .success(function(data) { $scope.canShareCredential = (data.count) ? true : false; + }).error(function (data, status) { + ProcessErrors($scope, data, status, null, { hdr: 'Error!', msg: 'Failed to find if users is admin of org' + status }); }); } @@ -342,6 +344,8 @@ export function CredentialsEdit($scope, $rootScope, $compile, $location, $log, Rest.get() .success(function(data) { $scope.canShareCredential = (data.count) ? true : false; + }).error(function (data, status) { + ProcessErrors($scope, data, status, null, { hdr: 'Error!', msg: 'Failed to find if users is admin of org' + status }); }); }