33 * Copyright © Magento, Inc. All rights reserved.
44 * See COPYING.txt for license details.
55 */
6+
7+ declare (strict_types=1 );
8+
69namespace Magento \Review \Model ;
710
11+ use Magento \Framework \App \ObjectManager ;
12+
813/**
9- * Class Rss
10- * @package Magento\Catalog\Model\Rss\Product
14+ * Model Rss
15+ *
16+ * Class \Magento\Catalog\Model\Rss\Product\Rss
1117 */
1218class Rss extends \Magento \Framework \Model \AbstractModel
1319{
@@ -24,18 +30,35 @@ class Rss extends \Magento\Framework\Model\AbstractModel
2430 protected $ eventManager ;
2531
2632 /**
33+ * Rss constructor.
34+ *
2735 * @param \Magento\Framework\Event\ManagerInterface $eventManager
2836 * @param ReviewFactory $reviewFactory
37+ * @param \Magento\Framework\Model\Context|null $context
38+ * @param \Magento\Framework\Registry|null $registry
39+ * @param \Magento\Framework\Model\ResourceModel\AbstractResource|null $resource
40+ * @param \Magento\Framework\Data\Collection\AbstractDb|null $resourceCollection
41+ * @param array $data
2942 */
3043 public function __construct (
3144 \Magento \Framework \Event \ManagerInterface $ eventManager ,
32- \Magento \Review \Model \ReviewFactory $ reviewFactory
45+ \Magento \Review \Model \ReviewFactory $ reviewFactory ,
46+ \Magento \Framework \Model \Context $ context = null ,
47+ \Magento \Framework \Registry $ registry = null ,
48+ \Magento \Framework \Model \ResourceModel \AbstractResource $ resource = null ,
49+ \Magento \Framework \Data \Collection \AbstractDb $ resourceCollection = null ,
50+ array $ data = []
3351 ) {
3452 $ this ->reviewFactory = $ reviewFactory ;
3553 $ this ->eventManager = $ eventManager ;
54+ $ context = $ context ?? ObjectManager::getInstance ()->get (\Magento \Framework \Model \Context::class);
55+ $ registry = $ registry ?? ObjectManager::getInstance ()->get (\Magento \Framework \Registry::class);
56+ parent ::__construct ($ context , $ registry , $ resource , $ resourceCollection , $ data );
3657 }
3758
3859 /**
60+ * Get Product Collection
61+ *
3962 * @return $this|\Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection
4063 */
4164 public function getProductCollection ()
0 commit comments