# $productPage->reduceStock()

> Lowers the stock by the quantity ordered

- Source: `src/ProductPage.php#L131` <https://github.com/wagnerwagner/merx/blob/2.0.0-alpha.11/src/ProductPage.php#L131>

```php
$productPage->reduceStock(float $quantity): Wagnerwagner\Merx\ProductPage
```

## Parameters

| Name | Type | Default |
| --- | --- | --- |
| `$quantity` | `float` | `–` |

## Return type

`Wagnerwagner\Merx\ProductPage`

The updated page

## Description

Merx calls it for every product of a new order, while
`wagnerwagner.merx.reduceStock` is true. Override it together with
`stock()` when the stock is kept somewhere else, e.g. in an ERP.

## Parent class

`Wagnerwagner\Merx\ProductPage`
