/**
  * @return AbstractCollection|mixed
  */
 public function _getProductCollection()
 {
     try {
         $layer = $this->getLayer();
         if ($this->bxHelperData->isFilterLayoutEnabled($layer)) {
             if (count($this->_productCollection) && !$this->p13nHelper->areThereSubPhrases()) {
                 return $this->_productCollection;
             }
             if ($layer instanceof \Magento\Catalog\Model\Layer\Category) {
                 if ($this->categoryViewBlock->isContentMode()) {
                     return parent::_getProductCollection();
                 }
             }
             if ($this->p13nHelper->areThereSubPhrases()) {
                 $this->queries = $this->p13nHelper->getSubPhrasesQueries();
                 $entity_ids = $this->p13nHelper->getSubPhraseEntitiesIds($this->queries[self::$number]);
                 $entity_ids = array_slice($entity_ids, 0, $this->bxHelperData->getSubPhrasesLimit());
             } else {
                 $entity_ids = $this->p13nHelper->getEntitiesIds();
             }
             if (count($entity_ids) == 0) {
                 $entity_ids = array(0);
             }
             $this->_setupCollection($entity_ids);
             return $this->_productCollection;
         } else {
             return parent::_getProductCollection();
         }
     } catch (\Exception $e) {
         $this->bxHelperData->setFallback(true);
         $this->_logger->critical($e);
         return parent::_getProductCollection();
     }
 }