2018-07-18 15:48:30 -04:00
|
|
|
import { connect } from 'react-redux';
|
2019-08-20 08:29:59 -04:00
|
|
|
import { doWalletStatus, doWalletEncrypt, selectWalletEncryptSucceeded, selectWalletEncryptResult } from 'lbry-redux';
|
2019-08-27 22:35:07 -04:00
|
|
|
import { doHideModal } from 'redux/actions/app';
|
2018-07-18 15:48:30 -04:00
|
|
|
import ModalWalletEncrypt from './view';
|
|
|
|
|
|
|
|
const select = state => ({
|
|
|
|
walletEncryptSucceded: selectWalletEncryptSucceeded(state),
|
|
|
|
walletEncryptResult: selectWalletEncryptResult(state),
|
|
|
|
});
|
|
|
|
|
|
|
|
const perform = dispatch => ({
|
2018-10-29 13:23:53 -04:00
|
|
|
closeModal: () => dispatch(doHideModal()),
|
2018-07-18 15:48:30 -04:00
|
|
|
encryptWallet: password => dispatch(doWalletEncrypt(password)),
|
|
|
|
updateWalletStatus: () => dispatch(doWalletStatus()),
|
|
|
|
});
|
|
|
|
|
|
|
|
export default connect(
|
|
|
|
select,
|
|
|
|
perform
|
|
|
|
)(ModalWalletEncrypt);
|