fix: capture one time and subscriptions separately (#38630)

This commit is contained in:
Ahmad Abdolsaheb
2020-04-24 19:57:19 +03:00
committed by GitHub
parent 11868700ad
commit a45df11de1
2 changed files with 16 additions and 7 deletions

View File

@@ -97,10 +97,9 @@ export class PaypalButton extends Component {
});
}}
isSubscription={isSubscription}
onApprove={(data, actions) => {
return actions.order.capture().then(function(data) {
this.handleApproval(data);
});
on={true}
onApprove={data => {
this.handleApproval(data);
}}
onCancel={() => {
this.props.onDonationStateChange(