Skip to content

Commit ca4128c

Browse files
committed
ENGCOM-3572: Static tests fixed.
1 parent ca9f63b commit ca4128c

File tree

1 file changed

+18
-8
lines changed
  • app/code/Magento/Review/Model/ResourceModel

1 file changed

+18
-8
lines changed

app/code/Magento/Review/Model/ResourceModel/Rating.php

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
*
1616
* @author Magento Core Team <[email protected]>
1717
* @since 100.0.2
18+
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
1819
*/
1920
class Rating extends \Magento\Framework\Model\ResourceModel\Db\AbstractDb
2021
{
@@ -43,13 +44,13 @@ class Rating extends \Magento\Framework\Model\ResourceModel\Db\AbstractDb
4344
private $scopeConfig;
4445

4546
/**
46-
* @param \Magento\Framework\Model\ResourceModel\Db\Context $context
47-
* @param \Psr\Log\LoggerInterface $logger
48-
* @param \Magento\Framework\Module\Manager $moduleManager
49-
* @param \Magento\Store\Model\StoreManagerInterface $storeManager
50-
* @param \Magento\Review\Model\ResourceModel\Review\Summary $reviewSummary
51-
* @param string $connectionName
52-
* @param ScopeConfigInterface|null $scopeConfig
47+
* @param \Magento\Framework\Model\ResourceModel\Db\Context $context
48+
* @param \Psr\Log\LoggerInterface $logger
49+
* @param \Magento\Framework\Module\Manager $moduleManager
50+
* @param \Magento\Store\Model\StoreManagerInterface $storeManager
51+
* @param Review\Summary $reviewSummary
52+
* @param string $connectionName
53+
* @param ScopeConfigInterface|null $scopeConfig
5354
*/
5455
public function __construct(
5556
\Magento\Framework\Model\ResourceModel\Db\Context $context,
@@ -189,6 +190,8 @@ protected function _afterSave(\Magento\Framework\Model\AbstractModel $object)
189190
}
190191

191192
/**
193+
* Process rating codes.
194+
*
192195
* @param \Magento\Framework\Model\AbstractModel $object
193196
* @return $this
194197
*/
@@ -212,6 +215,8 @@ protected function processRatingCodes(\Magento\Framework\Model\AbstractModel $ob
212215
}
213216

214217
/**
218+
* Process rating stores.
219+
*
215220
* @param \Magento\Framework\Model\AbstractModel $object
216221
* @return $this
217222
*/
@@ -235,6 +240,8 @@ protected function processRatingStores(\Magento\Framework\Model\AbstractModel $o
235240
}
236241

237242
/**
243+
* Delete rating data.
244+
*
238245
* @param int $ratingId
239246
* @param string $table
240247
* @param array $storeIds
@@ -258,6 +265,8 @@ protected function deleteRatingData($ratingId, $table, array $storeIds)
258265
}
259266

260267
/**
268+
* Insert rating data.
269+
*
261270
* @param string $table
262271
* @param array $data
263272
* @return void
@@ -280,6 +289,7 @@ protected function insertRatingData($table, array $data)
280289

281290
/**
282291
* Perform actions after object delete
292+
*
283293
* Prepare rating data for reaggregate all data for reviews
284294
*
285295
* @param \Magento\Framework\Model\AbstractModel $object
@@ -290,7 +300,7 @@ protected function _afterDelete(\Magento\Framework\Model\AbstractModel $object)
290300
parent::_afterDelete($object);
291301
if (!$this->moduleManager->isEnabled('Magento_Review') &&
292302
!$this->scopeConfig->getValue(
293-
\Magento\Review\Observer\PredispatchReviewObserver::XML_PATH_REVIEW_ACTIVE,
303+
\Magento\Review\Observer\PredispatchReviewObserver::XML_PATH_REVIEW_ACTIVE,
294304
\Magento\Store\Model\ScopeInterface::SCOPE_STORE
295305
)
296306
) {

0 commit comments

Comments
 (0)