lbry-desktop/ui/page/help/index.js

22 lines
650 B
JavaScript
Raw Normal View History

2019-09-26 12:07:11 -04:00
import * as PAGES from 'constants/pages';
import { connect } from 'react-redux';
2018-09-23 23:44:42 -04:00
import { doFetchAccessToken, selectAccessToken, selectUser } from 'lbryinc';
import { selectDaemonSettings } from 'redux/selectors/settings';
import HelpPage from './view';
2017-07-20 15:03:01 -04:00
const select = state => ({
user: selectUser(state),
2017-07-21 13:23:39 +07:00
accessToken: selectAccessToken(state),
deamonSettings: selectDaemonSettings(state),
2017-07-20 15:03:01 -04:00
});
2017-04-07 12:15:22 +07:00
2019-04-04 18:23:12 -04:00
const perform = (dispatch, ownProps) => ({
doAuth: () => ownProps.history.push(`/$/${PAGES.AUTH}?redirect=/$/${PAGES.HELP}`),
2017-07-21 13:23:39 +07:00
fetchAccessToken: () => dispatch(doFetchAccessToken()),
2017-06-05 21:21:55 -07:00
});
2017-05-21 18:34:12 -04:00
export default connect(
select,
perform
)(HelpPage);