Merge pull request #306 from isocolsky/rm/delete-words
Remove "delete words" option
This commit is contained in:
commit
e0582c0153
4 changed files with 0 additions and 60 deletions
|
|
@ -1,22 +0,0 @@
|
|||
'use strict';
|
||||
|
||||
angular.module('copayApp.controllers').controller('preferencesDeleteWordsController', function($scope, $ionicHistory, $stateParams, gettextCatalog, confirmDialog, lodash, profileService, gettext) {
|
||||
var wallet = profileService.getWallet($stateParams.walletId);
|
||||
var msg = gettext('Are you sure you want to delete the recovery phrase?');
|
||||
var successMsg = gettext('Recovery phrase deleted');
|
||||
$scope.needsBackup = wallet.needsBackup;
|
||||
|
||||
if (lodash.isEmpty(wallet.credentials.mnemonic) && lodash.isEmpty(wallet.credentials.mnemonicEncrypted))
|
||||
$scope.deleted = true;
|
||||
|
||||
$scope.delete = function() {
|
||||
confirmDialog.show(msg, function(ok) {
|
||||
if (ok) {
|
||||
wallet.clearMnemonic();
|
||||
profileService.updateCredentials(JSON.parse(wallet.export()), function() {
|
||||
$ionicHistory.goBack();
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
});
|
||||
|
|
@ -518,15 +518,6 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr
|
|||
}
|
||||
}
|
||||
})
|
||||
.state('tabs.preferences.deleteWords', {
|
||||
url: '/deleteWords',
|
||||
views: {
|
||||
'tab-settings@tabs': {
|
||||
controller: 'preferencesDeleteWordsController',
|
||||
templateUrl: 'views/preferencesDeleteWords.html'
|
||||
}
|
||||
}
|
||||
})
|
||||
.state('tabs.preferences.delete', {
|
||||
url: '/delete',
|
||||
views: {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue