1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-18 17:23:37 +00:00

handle user upgrade path for lock options gracefully with a log out prompt. Fixed log out bug on lock page.

This commit is contained in:
Kyle Spearrin
2016-10-26 00:56:46 -04:00
parent eff7e5431b
commit a462f728d3
2 changed files with 36 additions and 16 deletions

View File

@@ -7,21 +7,19 @@
$('#master-password').focus();
$scope.logOut = function () {
loginService.logOut(function () {
SweetAlert.swal({
title: 'Log Out',
text: 'Are you sure you want to log out?',
showCancelButton: true,
confirmButtonText: 'Yes',
cancelButtonText: 'Cancel'
}, function (confirmed) {
if (confirmed) {
loginService.logOut(function () {
$analytics.eventTrack('Logged Out');
$state.go('home');
});
}
});
SweetAlert.swal({
title: 'Log Out',
text: 'Are you sure you want to log out?',
showCancelButton: true,
confirmButtonText: 'Yes',
cancelButtonText: 'Cancel'
}, function (confirmed) {
if (confirmed) {
loginService.logOut(function () {
$analytics.eventTrack('Logged Out');
$state.go('home');
});
}
});
};