Skip to content

Commit 14a03dc

Browse files
committed
Merge remote-tracking branch '33876/patch-11' into commpr-10131-1006
2 parents 4d07ff3 + b4356e4 commit 14a03dc

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

app/code/Magento/Review/Controller/Product/ListAjax.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/**
3-
* Copyright © Magento, Inc. All rights reserved.
4-
* See COPYING.txt for license details.
3+
* Copyright 2011 Adobe
4+
* All Rights Reserved.
55
*/
66

77
namespace Magento\Review\Controller\Product;
@@ -22,7 +22,9 @@ class ListAjax extends ProductController implements HttpGetActionInterface
2222
*/
2323
public function execute()
2424
{
25-
if (!$this->initProduct()) {
25+
if (!$this->getRequest()->isAjax() ||
26+
!$this->initProduct()
27+
) {
2628
/** @var \Magento\Framework\Controller\Result\Forward $resultForward */
2729
$resultForward = $this->resultFactory->create(ResultFactory::TYPE_FORWARD);
2830
return $resultForward->forward('noroute');

0 commit comments

Comments
 (0)