During order refresh, promotions are loaded. Promotions that target order items may be processed. These will then throw missing context errors.

the applies method should ensure the offer type target entity matches the incoming entity.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mglaman created an issue. See original summary.

mglaman’s picture

Status: Active » Needs work
Issue tags: +Needs tests
FileSize
869 bytes

This gets it working. However we need tests on this.

mitrpaka’s picture

Status: Needs work » Needs review
Issue tags: -Needs tests
FileSize
2.77 KB
1.79 KB

Tests added.

mitrpaka’s picture

FileSize
2.79 KB
1.81 KB

  • mglaman committed 5c7ffac on 8.x-2.x authored by mitrpaka
    Issue #2826222 by mitrpaka, mglaman: Promotions should verify the offer...
mglaman’s picture

Status: Needs review » Fixed

Thanks for the tests! Committed.

Status: Fixed » Closed (fixed)

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