lbry-desktop/ui/js/component/userEmailNew/index.js

20 lines
534 B
JavaScript
Raw Normal View History

2017-06-10 19:17:37 +02:00
import React from "react";
import { connect } from "react-redux";
2017-08-18 05:31:44 +02:00
import { doUserEmailNew, doUserInviteNew } from "actions/user";
import {
selectEmailNewIsPending,
selectEmailNewErrorMessage,
2017-06-10 19:17:37 +02:00
} from "selectors/user";
import UserEmailNew from "./view";
2017-06-10 19:17:37 +02:00
const select = state => ({
isPending: selectEmailNewIsPending(state),
errorMessage: selectEmailNewErrorMessage(state),
2017-06-10 19:17:37 +02:00
});
2017-06-10 19:17:37 +02:00
const perform = dispatch => ({
addUserEmail: email => dispatch(doUserEmailNew(email)),
});
2017-06-10 19:17:37 +02:00
export default connect(select, perform)(UserEmailNew);