0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-17 23:44:39 -05:00

Updated paid signup action of member to include name

refs https://github.com/TryGhost/members.js/issues/29

- Uses updated API endpoint for checkout to pass member name in stripe checkout session metadata
This commit is contained in:
Rish 2020-05-20 00:10:46 +05:30
parent 43106c037e
commit 2b34ee5c28

View file

@ -156,11 +156,11 @@ export default class ParentContainer extends React.Component {
page: 'magiclink'
});
} else if (action === 'signup') {
const {plan, email} = data;
const {plan, email, name} = data;
if (plan.toLowerCase() === 'free') {
await this.GhostApi.member.sendMagicLink(data);
} else {
await this.GhostApi.member.checkoutPlan({plan, email});
await this.GhostApi.member.checkoutPlan({plan, email, name});
}
this.setState({
action: 'signup:success',