react-paypal-js
                                
                                
                                
                                    react-paypal-js copied to clipboard
                            
                            
                            
                        [BUG]: Actions.order.get() returns PickUp Instead Of Delivery
Is there an existing issue for this?
- [X] I have searched the existing issues.
 
🐞 Describe the Bug
Hi
Even though our customers are choosing a delivery fee in PayPal - our app is patching PP properly with the fee - our orders are created as a PickUp.
I am logging the response from order.get() to our Highlight service and it is showing that PayPal returns 'PICKUP', not 'DELIVERY', on these orders.
Any insight would be helpful here. Should I delay the request to PayPal? I have taken off the ability for our customers to Pick Up from us until I can resolve this issue.
TIA
` const onApprove = (data, actions) => {
    return actions.order.get().then(order => {
        // Get the selected option from the order
        const selectedOption = (order.purchase_units[0].shipping.options || []).filter(option => option.selected).pop();
        H.track("Get Shipping Type From PayPal", {
            shippingType: selectedOption.type
        })
        if (selectedOption.type !== 'PICKUP') return;
       .....
}
`
😕 Current Behavior
Delivery orders are being returned as Pick Up orders from PayPal.
🤔 Expected Behavior
Delivery orders are should be returned as Pick Up orders from PayPal.
🔬 Minimal Reproduction
No response
🌍 Environment
| Software         | Version(s) |
| ---------------- | ---------- |
| react-paypal-js  |            |
| Browser          |            |
| Operating System |            |
Relevant log output
No response
Code of Conduct
- [X] I agree to follow this project's Code of Conduct
 
➕ Anything else?
No response