src/components/entry/SelectWallet.js
//This happens when you click proceed under the password entry for the unencrypted wallet
This happens when you click proceed under the password entry for the unencrypted wallet
This happens when you click proceed under the password entry for the unencrypted wallet
walletResetDlUnencrypted(e) {
        e.preventDefault();
        localStorage.setItem('password', e.target.password.value);
        let wallet;
        try {
            wallet = decryptWalletData();
        }
        catch (err) {
            console.error(err);
            this.wrongPassword();
            return;
        }
        let niceKeys = '';
        const keys = wallet['keys'];
        keys.forEach((key) => {
            niceKeys += "private key: " + key.private_key + '\n';
            niceKeys += "public key: " + key.public_key + '\n';
            niceKeys += '\n';
        });
        const date = Date.now();
        fileDownload(niceKeys, date + '_unsafex.txt');
        this.setState({
            walletResetModal1: false,
            walletResetModal2unencrypted: false
        });
        this.openWalletResetModal('walletResetModalDlUnencrypted', 'During this stage you will be able to backup your encrypted wallet file. You may need it in the future and that is why this step exists.');
    }
walletResetDlUnencrypted ( e ) { e . preventDefault ( ) ; localStorage . setItem ( 'password' , e . target . password . value ) ; let wallet ; try { wallet = decryptWalletData ( ) ; } catch ( err ) { console . error ( err ) ; this . wrongPassword ( ) ; return ; } let niceKeys = '' ; const keys = wallet [ 'keys' ] ; keys . forEach ( ( key ) => { niceKeys += "private key: " + key . private_key + '\n' ; niceKeys += "public key: " + key . public_key + '\n' ; niceKeys += '\n' ; } ) ; const date = Date . now ( ) ; fileDownload ( niceKeys , date + '_unsafex.txt' ) ; this . setState ( { walletResetModal1 : false , walletResetModal2unencrypted : false } ) ; this . openWalletResetModal ( 'walletResetModalDlUnencrypted' , 'During this stage you will be able to backup your encrypted wallet file. You may need it in the future and that is why this step exists.' ) ; }
This happens when you click proceed under the password entry for the unencrypted wallet
This happens when you click proceed under the password entry for the unencrypted wallet