Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The order object ($arg1) is empty for the callback function of hook_checkout_pane on the operation "view". Can anyone confirm this or why is that?
Comments
Comment #1
Island Usurper CreditAttribution: Island Usurper commentedWhen someone first gets to the checkout page, there isn't an order yet, so NULL is passed into $arg1. If someone clicks "Back" on the review page, the order does exist by that point, and it should be used to fill in the #default_values of the checkout form rather than the actual default values. This keeps them from having to fill out all of their information again.