InvalidStockLevelsInCartException::__construct( string $error_code, WP_Error $error, array $additional_data = array() )
Setup exception.
Description Description
Parameters Parameters
- $error_code
-
(Required) Machine-readable error code, e.g
woocommerce_invalid_product_id
. - $error
-
(Required) The WP_Error object containing all errors relating to stock availability.
- $additional_data
-
(Optional) Extra data (key value pairs) to expose in the error response.
Default value: array()
Source Source
File: packages/woocommerce-blocks/src/StoreApi/Utilities/InvalidStockLevelsInCartException.php