Skip to content

Commit d69525e

Browse files
Merge pull request #1074 from magento-engcom/develop-prs
[EngCom] Public Pull Requests - MAGETWO-67723: Add logging to contact us form #9343 - MAGETWO-67721: Remove context aggregation validation (see Issue #6114) #8955 - MAGETWO-68767: Use loadPlayer requirejs mapping #9414 - MAGETWO-68770: Fix addIdFilter method #9400
2 parents 5ea676e + 9f4d186 commit d69525e

File tree

9 files changed

+14
-335
lines changed

9 files changed

+14
-335
lines changed

app/code/Magento/Catalog/Model/ResourceModel/Category/Flat/Collection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ public function addIdFilter($categoryIds)
119119
$condition = ['in' => $ids];
120120
}
121121
}
122-
$this->addFieldToFilter('entity_id', $condition);
122+
$this->addFieldToFilter('main_table.entity_id', $condition);
123123
return $this;
124124
}
125125

app/code/Magento/Contact/Controller/Index/Post.php

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
use Magento\Framework\Controller\Result\Redirect;
1515
use Magento\Framework\Exception\LocalizedException;
1616
use Magento\Framework\HTTP\PhpEnvironment\Request;
17+
use Psr\Log\LoggerInterface;
1718

1819
class Post extends \Magento\Contact\Controller\Index
1920
{
@@ -32,22 +33,30 @@ class Post extends \Magento\Contact\Controller\Index
3233
*/
3334
private $mail;
3435

36+
/**
37+
* @var LoggerInterface
38+
*/
39+
private $logger;
40+
3541
/**
3642
* @param Context $context
3743
* @param ConfigInterface $contactsConfig
3844
* @param MailInterface $mail
3945
* @param DataPersistorInterface $dataPersistor
46+
* @param LoggerInterface $logger
4047
*/
4148
public function __construct(
4249
Context $context,
4350
ConfigInterface $contactsConfig,
4451
MailInterface $mail,
45-
DataPersistorInterface $dataPersistor
52+
DataPersistorInterface $dataPersistor,
53+
LoggerInterface $logger = null
4654
) {
4755
parent::__construct($context, $contactsConfig);
4856
$this->context = $context;
4957
$this->mail = $mail;
5058
$this->dataPersistor = $dataPersistor;
59+
$this->logger = $logger ?: \Magento\Framework\App\ObjectManager::getInstance()->get(LoggerInterface::class);
5160
}
5261

5362
/**
@@ -70,8 +79,9 @@ public function execute()
7079
$this->messageManager->addErrorMessage($e->getMessage());
7180
$this->getDataPersistor()->set('contact_us', $this->getRequest()->getParams());
7281
} catch (\Exception $e) {
82+
$this->logger->critical($e);
7383
$this->messageManager->addErrorMessage(
74-
__('We can\'t process your request right now. Sorry, that\'s all we know.')
84+
__('An error occurred while processing your form. Please try again later.')
7585
);
7686
$this->getDataPersistor()->set('contact_us', $this->getRequest()->getParams());
7787
}

app/code/Magento/ProductVideo/view/frontend/web/js/fotorama-add-video-events.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ define([
77
'jquery',
88
'jquery/ui',
99
'catalogGallery',
10-
'Magento_ProductVideo/js/load-player'
10+
'loadPlayer'
1111
], function ($) {
1212
'use strict';
1313

dev/tests/static/testsuite/Magento/Test/Integrity/Di/CompilerTest.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,6 @@ protected function setUp()
101101
);
102102
$this->_validator = new \Magento\Framework\Code\Validator();
103103
$this->_validator->add(new \Magento\Framework\Code\Validator\ConstructorIntegrity());
104-
$this->_validator->add(new \Magento\Framework\Code\Validator\ContextAggregation());
105104
$this->_validator->add(new \Magento\Framework\Code\Validator\TypeDuplication());
106105
$this->_validator->add(new \Magento\Framework\Code\Validator\ArgumentSequence());
107106
$this->_validator->add(new \Magento\Framework\Code\Validator\ConstructorArgumentTypes());

lib/internal/Magento/Framework/Code/Test/Unit/Validator/ContextAggregationTest.php

Lines changed: 0 additions & 59 deletions
This file was deleted.

lib/internal/Magento/Framework/Code/Test/Unit/Validator/_files/ClassesForContextAggregation.php

Lines changed: 0 additions & 169 deletions
This file was deleted.

0 commit comments

Comments
 (0)