Call to a member function getRemoteId() on null

Created on 28 October 2024, about 1 month ago

Problem/Motivation

During the order assign event, the payment method might be updated.

In a specific case, the payment method may be NULL. This causes an error to be logged. Since this is wrapped in a try/catch, this isn't detrimental, but it would be good to reduce the noise, if reasonable.

The payment method should normally be set if we have a payment intent and the order is being assigned. This typically happens when the order is completed for an anonymous user, who then creates an account, to which the order is assigned.

Another scenario, though, occurs if an anonymous user begins the checkout process (creating the payment intent), then signs into their existing account before creating a new payment method. In this scenario, the payment method will be NULL.

Proposed resolution

We should check if the payment method is NULL.

πŸ“Œ Task
Status

Active

Version

1.0

Component

Payment Element

Created by

πŸ‡ΊπŸ‡ΈUnited States TomTech

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024