"Shipment items" must be validated before "Recalculate shipping" click

Created on 8 May 2025, about 1 month ago

Problem/Motivation

Commerce UPS and one of our custom shipping method plugin fails for the similar error, i.e. Error: Call to a member function getUnit() on null in Drupal\commerce_ups\UPSSdk->getPackages() (line 289 of /var/www/html/web/modules/contrib/commerce_ups/src/UPSSdk.php)

Follow the parent issue Error: Call to a member function getUnit() on null 🐛 Error: Call to a member function getUnit() on null Active for more details.

Instead of validating each shipping method plugin for getWeight(), we should consider validating the field "Shipment items" on "Recalculate shipping" button click.

🐛 Bug report
Status

Active

Version

2.0

Component

Code

Created by

🇮🇳India vipin.j

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