Skip to content

Commit

Permalink
Merge pull request #1323 from mailchimp/Issue1322-2.1
Browse files Browse the repository at this point in the history
closes #1322 for magento 2.1
  • Loading branch information
gonzaloebiz authored Dec 13, 2021
2 parents b519677 + cd3c2a1 commit 4ee4ac9
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Model/Config/Backend/MonkeyStore.php
Original file line number Diff line number Diff line change
Expand Up @@ -114,14 +114,17 @@ public function beforeSave()
$this->getScopeId(),
$this->getScope()
);
$this->_helper->saveJsUrl($this->getScopeId(),$this->getScope(),$this->getValue());

foreach ($this->_storeManager->getStores() as $storeId => $val) {
$mstoreId = $this->_helper->getConfigValue(
\Ebizmarts\MailChimp\Helper\Data::XML_MAILCHIMP_STORE,
$storeId
);
if ($mstoreId == $mailchimpStore) {
$this->_helper->deleteConfig(
\Ebizmarts\MailChimp\Helper\Data::XML_MAILCHIMP_JS_URL,
$storeId,
'stores'
);
$found++;
}
$listId = $this->_helper->getConfigValue(\Ebizmarts\MailChimp\Helper\Data::XML_PATH_LIST, $storeId);
Expand Down

0 comments on commit 4ee4ac9

Please sign in to comment.