Skip to content

Commit

Permalink
MAGETWO-66427: Unable to save subscription checkbox on Admin customer…
Browse files Browse the repository at this point in the history
… save #6811
  • Loading branch information
Oleksii Korshenko authored Mar 23, 2017
2 parents 1b44e50 + 7d6e9a2 commit fe5c592
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ public function execute()
$isSubscribed = $this->getRequest()->getPost('subscription');
}
if ($isSubscribed !== null) {
if ($isSubscribed !== 'false') {
if ($isSubscribed !== '0') {
$this->_subscriberFactory->create()->subscribeCustomerById($customerId);
} else {
$this->_subscriberFactory->create()->unsubscribeCustomerById($customerId);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ public function testSaveActionExistingCustomerUnsubscribeNewsletter()
'firstname' => 'test firstname',
'lastname' => 'test lastname',
],
'subscription' => 'false'
'subscription' => '0'
];
$this->getRequest()->setPostValue($post);
$this->getRequest()->setParam('id', 1);
Expand Down

0 comments on commit fe5c592

Please sign in to comment.