On PHP 7.4+ you might see an array access error on a boolean value when rendering a View that uses the order balance Views field. The reason is sometimes commerce_payment_order_balance() is FALSE. In my testing, this was due to an order having an order total in one currency but payment totals in another.

This issue is for the quick fix of accommodating the FALSE return value. There are legitimate reasons a balance may be indeterminate, and we should support that.

I'm going to open a separate issue for researching why I had a mismatch, because I did not expect that. 😅

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

rszrama created an issue. See original summary.

rszrama’s picture

Priority: Normal » Minor
FileSize
909 bytes

Patch attached.

rszrama’s picture

Status: Needs review » Fixed

Committed!

  • rszrama committed e791750 on 7.x-1.x
    Issue #3253379 by rszrama: Show a placeholder when an order balance...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.