diff --git a/functions/product.php b/functions/product.php index 73182896..3f37d46f 100644 --- a/functions/product.php +++ b/functions/product.php @@ -387,7 +387,7 @@ function doliProductCart($product, $refresh = null, $wishlist = true, $related = if ( empty(doliconnectid('dolicart')) || empty(doliconnectid('dolicart')) ) { $button .= "".__( 'Contact us', 'doliconnect').''; } elseif ( is_user_logged_in() && doliCheckModules('commande', $refresh) && doliconnectid('dolicart') > 0 ) { - if (!empty($related) && $mstock['fk_parent_line']) { + if (!empty($related) && !empty($mstock['fk_parent_line'])) { $button .= ''; } elseif ( $mstock['stock'] <= 0 || $mstock['m2'] < $mstock['step'] ) { $button .= '