From 87f0e2be0e018ba8606f53a67691356365c25ef0 Mon Sep 17 00:00:00 2001 From: Kyle Spearrin Date: Wed, 12 Jul 2017 10:00:36 -0400 Subject: [PATCH] cleanup --- src/app/directives/totpDirective.js | 6 ++++++ src/app/vault/vaultAttachmentsController.js | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/app/directives/totpDirective.js b/src/app/directives/totpDirective.js index 163273586c..5b3d2dfb16 100644 --- a/src/app/directives/totpDirective.js +++ b/src/app/directives/totpDirective.js @@ -164,6 +164,12 @@ angular }, 1000); }); + scope.$on("$destroy", function () { + if (interval) { + clearInterval(interval); + } + }); + scope.clipboardError = function (e) { alert('Your web browser does not support easy clipboard copying.'); }; diff --git a/src/app/vault/vaultAttachmentsController.js b/src/app/vault/vaultAttachmentsController.js index f7abc6caeb..af718e1a4b 100644 --- a/src/app/vault/vaultAttachmentsController.js +++ b/src/app/vault/vaultAttachmentsController.js @@ -31,7 +31,7 @@ return apiService.ciphers.postAttachment({ id: loginId }, fd).$promise; }).then(function (response) { $analytics.eventTrack('Added Attachment'); - toastr.success('The attachment has been added.'); + toastr.success('The attachment has been saved.'); closing = true; $uibModalInstance.close(true); }, function (err) {