You are here

public function Shipment::removeAdjustment in Commerce Shipping 8.2

Removes an adjustment.

Parameters

\Drupal\commerce_order\Adjustment $adjustment: The adjustment to remove.

Return value

$this

Overrides EntityAdjustableInterface::removeAdjustment

File

src/Entity/Shipment.php, line 405

Class

Shipment
Defines the shipment entity class.

Namespace

Drupal\commerce_shipping\Entity

Code

public function removeAdjustment(Adjustment $adjustment) {
  $this
    ->get('adjustments')
    ->removeAdjustment($adjustment);
  return $this;
}