wc_product_pre_lock_on_sku
wc_product_pre_lock_on_sku
Appears in: woocommerce.9.3.1, woocommerce.9.3.3, woocommerce.9.4.2, woocommerce.9.4.3, woocommerce.9.5.1
Hook Type: filter
Displaying hooks found in version: woocommerce.9.5.1apply_filters('wc_product_pre_lock_on_sku') is found 1 times:
- /includes/data-stores/class-wc-product-data-store-cpt.php line 145
* * @param bool|null $locked Set to a boolean value to short-circuit the SKU lock query. * @param WC_Product $product The product being created. */ $locked = apply_filters( 'wc_product_pre_lock_on_sku', null, $product ); if ( ! is_null( $locked ) ) { return boolval( $locked ); } // The insert query can potentially result in a deadlock if there is high concurrency // when trying to insert products, which will result in a false negative for SKU lock