Skip to content

Commit

Permalink
Only work on shipping address.
Browse files Browse the repository at this point in the history
  • Loading branch information
domeglic committed Jan 31, 2019
1 parent 51a3506 commit 04f46a1
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions Observer/ResetGiftItems.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,13 @@ public function execute(Observer $observer)

if ($shippingAssignment instanceof ShippingAssignmentInterface)
{
/** @var Quote\Address $address */
$address = $shippingAssignment->getShipping()->getAddress();

if ($address->getAddressType() != Quote\Address::ADDRESS_TYPE_SHIPPING)
{
return;
}
}
else
{
Expand Down

0 comments on commit 04f46a1

Please sign in to comment.