Problem/Motivation

When retrieving payment results and there is a payment entity with no payment execution status the isCompleted() function triggers an exception which is blocking from retrieving valid entities.

Error: Call to a member function isCompleted() on bool in Drupal\payment\Entity\Payment\PaymentAccessControlHandler->checkAccess() (line 55 of modules/contrib/payment/src/Entity/Payment/PaymentAccessControlHandler.php).

Proposed resolution

Add extra check for getPaymentExecutionResult() returning FALSE.

Issue fork payment-3408147

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

TommieCrawford created an issue. See original summary.

TommieCrawford changed the visibility of the branch 3408147-error-when-there to hidden.

tommiecrawford’s picture

StatusFileSize
new1.01 KB

Created a patch with a extra check if getPaymentExecutionResult() is returning FALSE.

tommiecrawford’s picture

StatusFileSize
new787 bytes

Another patch with no formatting changes.