src/Backend/Modules/Commerce/Domain/Product/Product.php
/**
     * Check if the product is in stock.
     */
Check if the product is in stock.
Check if the product is in stock .
public function inStock(): bool
    {
        if (!$this->isFromStock()) {
            return true;
        }
        return $this->getStock() > 0;
    }
public function inStock ( ) : bool { if ( ! $ this -> isFromStock ( ) ) { return true ; } return $ this -> getStock ( ) > 0 ; }
Check if the product is in stock.
Check if the product is in stock .