$download = false; foreach ($this->getProducts() as $product) { if ($product['download']) { $download = true; break; } } return $download;