Skip to content

Commit e23249e

Browse files
[EngCom] Public Pull Requests - 2.3-develop
- merged latest code from mainline branch
2 parents 4aa3f65 + 9186f4a commit e23249e

File tree

37 files changed

+245
-94
lines changed

37 files changed

+245
-94
lines changed

app/code/Magento/AdvancedPricingImportExport/Test/Unit/Model/Import/AdvancedPricing/Validator/WebsiteTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,13 +103,13 @@ public function testGetAllWebsitesValue()
103103
$this->webSiteModel->expects($this->once())->method('getBaseCurrency')->willReturn($currency);
104104

105105
$expectedResult = AdvancedPricing::VALUE_ALL_WEBSITES . ' [' . $currencyCode . ']';
106-
$this->websiteString = $this->getMockBuilder(
106+
$websiteString = $this->getMockBuilder(
107107
\Magento\AdvancedPricingImportExport\Model\Import\AdvancedPricing\Validator\Website::class
108108
)
109109
->setMethods(['_clearMessages', '_addMessages'])
110110
->setConstructorArgs([$this->storeResolver, $this->webSiteModel])
111111
->getMock();
112-
$result = $this->websiteString->getAllWebsitesValue();
112+
$result = $websiteString->getAllWebsitesValue();
113113

114114
$this->assertEquals($expectedResult, $result);
115115
}

app/code/Magento/Catalog/i18n/en_US.csv

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,6 @@ Products,Products
233233
"This attribute set no longer exists.","This attribute set no longer exists."
234234
"You saved the attribute set.","You saved the attribute set."
235235
"Something went wrong while saving the attribute set.","Something went wrong while saving the attribute set."
236-
"You added product %1 to the comparison list.","You added product %1 to the comparison list."
237236
"You cleared the comparison list.","You cleared the comparison list."
238237
"Something went wrong clearing the comparison list.","Something went wrong clearing the comparison list."
239238
"You removed product %1 from the comparison list.","You removed product %1 from the comparison list."
@@ -808,4 +807,5 @@ Details,Details
808807
"Product Name or SKU", "Product Name or SKU"
809808
"Start typing to find products", "Start typing to find products"
810809
"Product with ID: (%1) doesn't exist", "Product with ID: (%1) doesn't exist"
811-
"Category with ID: (%1) doesn't exist", "Category with ID: (%1) doesn't exist"
810+
"Category with ID: (%1) doesn't exist", "Category with ID: (%1) doesn't exist"
811+
"You added product %1 to the <a href=""%2"">comparison list</a>.","You added product %1 to the <a href=""%2"">comparison list</a>."

app/code/Magento/CatalogImportExport/Model/Import/Uploader.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ class Uploader extends \Magento\MediaStorage\Model\File\Uploader
101101
* @param \Magento\MediaStorage\Model\File\Validator\NotProtectedExtension $validator
102102
* @param \Magento\Framework\Filesystem $filesystem
103103
* @param \Magento\Framework\Filesystem\File\ReadFactory $readFactory
104-
* @param null $filePath
104+
* @param null|string $filePath
105105
* @throws \Magento\Framework\Exception\LocalizedException
106106
*/
107107
public function __construct(
@@ -113,15 +113,15 @@ public function __construct(
113113
\Magento\Framework\Filesystem\File\ReadFactory $readFactory,
114114
$filePath = null
115115
) {
116-
if ($filePath !== null) {
117-
$this->_setUploadFile($filePath);
118-
}
119116
$this->_imageFactory = $imageFactory;
120117
$this->_coreFileStorageDb = $coreFileStorageDb;
121118
$this->_coreFileStorage = $coreFileStorage;
122119
$this->_validator = $validator;
123120
$this->_directory = $filesystem->getDirectoryWrite(DirectoryList::ROOT);
124121
$this->_readFactory = $readFactory;
122+
if ($filePath !== null) {
123+
$this->_setUploadFile($filePath);
124+
}
125125
}
126126

127127
/**
@@ -353,7 +353,7 @@ protected function _moveFile($tmpPath, $destPath)
353353
}
354354

355355
/**
356-
* {@inheritdoc}
356+
* @inheritdoc
357357
*/
358358
protected function chmod($file)
359359
{

app/code/Magento/Checkout/i18n/en_US.csv

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,3 +182,4 @@ Payment,Payment
182182
"Items in Cart","Items in Cart"
183183
"Close","Close"
184184
"Show Cross-sell Items in the Shopping Cart","Show Cross-sell Items in the Shopping Cart"
185+
"You added %1 to your <a href=""%2"">shopping cart</a>.","You added %1 to your <a href=""%2"">shopping cart</a>."

app/code/Magento/ConfigurableProduct/Controller/Adminhtml/Product/Initialization/Helper/Plugin/Configurable.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ protected function getVariationMatrix()
158158
$configurableMatrix = json_decode($configurableMatrix, true);
159159

160160
foreach ($configurableMatrix as $item) {
161-
if ($item['newProduct']) {
161+
if (isset($item['newProduct']) && $item['newProduct']) {
162162
$result[$item['variationKey']] = $this->mapData($item);
163163

164164
if (isset($item['qty'])) {

app/code/Magento/Customer/Block/Adminhtml/Edit/Tab/Orders.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ public function __construct(
5757
}
5858

5959
/**
60-
* {@inheritdoc}
60+
* @inheritdoc
6161
*/
6262
protected function _construct()
6363
{
@@ -102,7 +102,7 @@ protected function _prepareCollection()
102102
}
103103

104104
/**
105-
* {@inheritdoc}
105+
* @inheritdoc
106106
*/
107107
protected function _prepareColumns()
108108
{
@@ -123,7 +123,8 @@ protected function _prepareColumns()
123123
'header' => __('Order Total'),
124124
'index' => 'grand_total',
125125
'type' => 'currency',
126-
'currency' => 'order_currency_code'
126+
'currency' => 'order_currency_code',
127+
'rate' => 1
127128
]
128129
);
129130

@@ -162,7 +163,7 @@ public function getRowUrl($row)
162163
}
163164

164165
/**
165-
* {@inheritdoc}
166+
* @inheritdoc
166167
*/
167168
public function getGridUrl()
168169
{

app/code/Magento/Customer/Controller/Account/ForgotPassword.php

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<?php
22
/**
3-
*
43
* Copyright © Magento, Inc. All rights reserved.
54
* See COPYING.txt for license details.
65
*/
@@ -11,6 +10,9 @@
1110
use Magento\Framework\App\Action\Context;
1211
use Magento\Framework\View\Result\PageFactory;
1312

13+
/**
14+
* Forgot Password controller
15+
*/
1416
class ForgotPassword extends \Magento\Customer\Controller\AbstractAccount implements HttpGetActionInterface
1517
{
1618
/**
@@ -41,10 +43,17 @@ public function __construct(
4143
/**
4244
* Forgot customer password page
4345
*
44-
* @return \Magento\Framework\View\Result\Page
46+
* @return \Magento\Framework\Controller\Result\Redirect|\Magento\Framework\View\Result\Page
4547
*/
4648
public function execute()
4749
{
50+
if ($this->session->isLoggedIn()) {
51+
/** @var \Magento\Framework\Controller\Result\Redirect $resultRedirect */
52+
$resultRedirect = $this->resultRedirectFactory->create();
53+
$resultRedirect->setPath('*/*/');
54+
return $resultRedirect;
55+
}
56+
4857
/** @var \Magento\Framework\View\Result\Page $resultPage */
4958
$resultPage = $this->resultPageFactory->create();
5059
$resultPage->getLayout()->getBlock('forgotPassword')->setEmailValue($this->session->getForgottenEmail());

app/code/Magento/Customer/Model/AccountManagement.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -681,8 +681,8 @@ public function resetPassword($email, $resetToken, $newPassword)
681681
$customerSecure->setRpToken(null);
682682
$customerSecure->setRpTokenCreatedAt(null);
683683
$customerSecure->setPasswordHash($this->createPasswordHash($newPassword));
684-
$this->sessionManager->destroy();
685684
$this->destroyCustomerSessions($customer->getId());
685+
$this->sessionManager->destroy();
686686
$this->customerRepository->save($customer);
687687

688688
return true;

app/code/Magento/Customer/Model/Authentication.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ public function __construct(
8383
}
8484

8585
/**
86-
* {@inheritdoc}
86+
* @inheritdoc
8787
*/
8888
public function processAuthenticationFailure($customerId)
8989
{
@@ -120,7 +120,7 @@ public function processAuthenticationFailure($customerId)
120120
}
121121

122122
/**
123-
* {@inheritdoc}
123+
* @inheritdoc
124124
*/
125125
public function unlock($customerId)
126126
{
@@ -152,7 +152,7 @@ protected function getMaxFailures()
152152
}
153153

154154
/**
155-
* {@inheritdoc}
155+
* @inheritdoc
156156
*/
157157
public function isLocked($customerId)
158158
{
@@ -161,13 +161,13 @@ public function isLocked($customerId)
161161
}
162162

163163
/**
164-
* {@inheritdoc}
164+
* @inheritdoc
165165
*/
166166
public function authenticate($customerId, $password)
167167
{
168168
$customerSecure = $this->customerRegistry->retrieveSecureData($customerId);
169169
$hash = $customerSecure->getPasswordHash();
170-
if (!$this->encryptor->validateHash($password, $hash)) {
170+
if (!$hash || !$this->encryptor->validateHash($password, $hash)) {
171171
$this->processAuthenticationFailure($customerId);
172172
if ($this->isLocked($customerId)) {
173173
throw new UserLockedException(__('The account is locked.'));

app/code/Magento/Developer/etc/di.xml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -240,4 +240,12 @@
240240
</argument>
241241
</arguments>
242242
</type>
243+
244+
<type name="Magento\Developer\Model\TemplateEngine\Plugin\DebugHints">
245+
<arguments>
246+
<argument name="debugHintsPath" xsi:type="string">dev/debug/template_hints_storefront</argument>
247+
<argument name="debugHintsWithParam" xsi:type="string">dev/debug/template_hints_storefront_show_with_parameter</argument>
248+
<argument name="debugHintsParameter" xsi:type="string">dev/debug/template_hints_parameter_value</argument>
249+
</arguments>
250+
</type>
243251
</config>

0 commit comments

Comments
 (0)