1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-05 23:44:56 +01:00
metamask-extension/ui/components/app/modals/account-modal-container/account-modal-container.container.js

24 lines
580 B
JavaScript
Raw Normal View History

import { connect } from 'react-redux';
import { hideModal } from '../../../../store/actions';
import { getSelectedIdentity } from '../../../../selectors';
import AccountModalContainer from './account-modal-container.component';
2020-11-03 00:41:28 +01:00
function mapStateToProps(state, ownProps) {
return {
selectedIdentity: ownProps.selectedIdentity || getSelectedIdentity(state),
};
}
2020-11-03 00:41:28 +01:00
function mapDispatchToProps(dispatch) {
return {
hideModal: () => {
dispatch(hideModal());
},
};
}
2020-11-03 00:41:28 +01:00
export default connect(
mapStateToProps,
mapDispatchToProps,
)(AccountModalContainer);