From 11cbe3b7bb6b66b1adbca4869adb8fe047280b10 Mon Sep 17 00:00:00 2001 From: Kyle Spearrin Date: Fri, 7 Jul 2017 14:16:15 -0400 Subject: [PATCH] allow totp if from an org with totp --- src/app/vault/vaultEditLoginController.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/app/vault/vaultEditLoginController.js b/src/app/vault/vaultEditLoginController.js index 1e27dfd51b..19b1d171c9 100644 --- a/src/app/vault/vaultEditLoginController.js +++ b/src/app/vault/vaultEditLoginController.js @@ -10,11 +10,11 @@ authService.getUserProfile().then(function (profile) { $scope.useTotp = profile.premium; - }); - - apiService.logins.get({ id: loginId }, function (login) { + return apiService.logins.get({ id: loginId }).$promise; + }).then(function (login) { $scope.login = cipherService.decryptLogin(login); $scope.readOnly = !login.Edit; + $scope.useTotp = $scope.useTotp || $scope.login.organizationUseTotp; }); $scope.save = function (model) {