CartController::get_variation_id_from_variation_data( array $request, WC_Product $product )

Try to match request data to a variation ID and return the ID.


Description Description


Parameters Parameters

$request

(Required) Add to cart request params.

$product

(Required) Product being added to the cart.


Top ↑

Return Return

(int) Matching variation ID.


Top ↑

Source Source

File: packages/woocommerce-blocks/src/StoreApi/Utilities/CartController.php


			


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.