From d21d75d976ba07e013bfe18170dd71a32757ee8f Mon Sep 17 00:00:00 2001 From: brantje Date: Thu, 15 Sep 2016 07:09:39 +0200 Subject: [PATCH] Use private var --- js/app/controllers/credential.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/js/app/controllers/credential.js b/js/app/controllers/credential.js index 1e822e97..27ddbeab 100644 --- a/js/app/controllers/credential.js +++ b/js/app/controllers/credential.js @@ -32,15 +32,14 @@ angular.module('passmanApp') }; $scope.editCredential = function(credential){ - var credential = angular.copy(credential); + var _credential = angular.copy(credential); $rootScope.$emit('app_menu', false); - SettingsService.setSetting('edit_credential', CredentialService.encryptCredential(credential)); - $location.path('/vault/'+ $scope.active_vault.vault_id +'/edit/'+ credential.credential_id) + SettingsService.setSetting('edit_credential', CredentialService.encryptCredential(_credential)); + $location.path('/vault/'+ $scope.active_vault.vault_id +'/edit/'+ _credential.credential_id) }; $scope.selectedCredential = false; $scope.selectCredential = function (credential) { - console.log(credential); $scope.selectedCredential = CredentialService.decryptCredential(angular.copy(credential)); $rootScope.$emit('app_menu', true); };