1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-27 04:46:10 +01:00
metamask-extension/ui/app/pages/lock/lock.container.js

25 lines
525 B
JavaScript
Raw Normal View History

import Lock from './lock.component'
2020-02-24 23:58:26 +01:00
import { compose } from 'redux'
import { connect } from 'react-redux'
import { withRouter } from 'react-router-dom'
import { lockMetamask } from '../../store/actions'
2020-02-15 21:34:12 +01:00
const mapStateToProps = (state) => {
const { metamask: { isUnlocked } } = state
return {
isUnlocked,
}
}
2020-02-15 21:34:12 +01:00
const mapDispatchToProps = (dispatch) => {
return {
lockMetamask: () => dispatch(lockMetamask()),
}
}
export default compose(
withRouter,
connect(mapStateToProps, mapDispatchToProps)
)(Lock)