Skip to content

Commit 5e7f1ce

Browse files
committed
MC-38676: Fixed force logout after email change
1 parent 3a35b6e commit 5e7f1ce

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

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

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77

88
namespace Magento\Customer\Controller\Account;
99

10-
use Exception;
1110
use Magento\Customer\Api\Data\CustomerInterface;
1211
use Magento\Customer\Api\SessionCleanerInterface;
1312
use Magento\Customer\Model\AddressRegistry;
@@ -245,7 +244,7 @@ public function execute()
245244
}
246245
} catch (LocalizedException $e) {
247246
$this->messageManager->addErrorMessage($e->getMessage());
248-
} catch (Exception $e) {
247+
} catch (\Exception $e) {
249248
$this->messageManager->addException($e, __('We can\'t save the customer.'));
250249
}
251250

app/code/Magento/Customer/Test/Mftf/Test/StorefrontChangeCustomerEmailTest.xml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,18 +14,19 @@
1414
<stories value="Update Customer"/>
1515
<title value="Changing Customer Email Test"/>
1616
<description value="Changing Customer's email with correct and wrong passwords"/>
17-
<testCaseId value="MC-38725"/>
17+
<testCaseId value="MC-38729"/>
18+
<useCaseId value="MC-38676"/>
1819
<severity value="MAJOR"/>
1920
<group value="customer"/>
2021
</annotations>
2122
<before>
2223
<createData entity="Simple_US_Customer" stepKey="customer"/>
2324
</before>
2425
<after>
26+
<actionGroup ref="StorefrontCustomerLogoutActionGroup" stepKey="customerLogout"/>
2527
<deleteData createDataKey="customer" stepKey="deleteCustomer"/>
2628
</after>
2729

28-
<actionGroup ref="StorefrontOpenHomePageActionGroup" stepKey="openStorefrontHomePage"/>
2930
<actionGroup ref="LoginToStorefrontActionGroup" stepKey="loginToStorefrontAccount">
3031
<argument name="Customer" value="$customer$"/>
3132
</actionGroup>
@@ -46,7 +47,7 @@
4647
</actionGroup>
4748
<!-- Navigate to "Account Information" tab Second Time-->
4849
<actionGroup ref="StorefrontOpenCustomerAccountInfoEditPageActionGroup" stepKey="goToCustomerEditPageSecondTime" />
49-
<!-- Checking Email checkbox, entering new email, saving with incorrect password -->
50+
<!-- Entering new email, saving with wrong password -->
5051
<actionGroup ref="StorefrontCustomerChangeEmailActionGroup" stepKey="changeEmailWrongAttempt">
5152
<argument name="email" value="$customer.email$"/>
5253
<argument name="password" value="WRONG_PASSWORD_123123q"/>

0 commit comments

Comments
 (0)