Rename the import screen displayed flag so it doesn't clash with WC settings [MAILPOET-1983]

This commit is contained in:
wxa
2019-05-06 16:32:49 +03:00
committed by M. Shull
parent 251ff637cb
commit 20f3ce79e6
3 changed files with 3 additions and 3 deletions

View File

@@ -48,7 +48,7 @@ class WooCommerceImportController extends React.Component {
submit(importType) {
this.setState({ loading: true });
const settings = {
'woocommerce.import_screen_displayed': 1,
woocommerce_import_screen_displayed: 1,
'mailpoet_subscribe_old_woocommerce_customers.enabled': importType === 'subscribed' ? 1 : 0,
};
this.updateSettings(settings).then(this.scheduleImport).then(this.finishWizard);

View File

@@ -101,7 +101,7 @@ class Changelog {
}
if (
!in_array($_GET['page'], ['mailpoet-woocommerce-list-import', 'mailpoet-welcome-wizard', 'mailpoet-migration'])
&& !$this->settings->get('woocommerce.import_screen_displayed')
&& !$this->settings->get('woocommerce_import_screen_displayed')
&& $this->wooCommerceHelper->isWooCommerceActive()
&& $this->wooCommerceHelper->getOrdersCount() >= 1
&& $this->wp->currentUserCan('administrator')

View File

@@ -96,7 +96,7 @@ class Settings {
}
function withWooCommerceListImportPageDisplayed($was_shown) {
$this->settings->set('woocommerce.import_screen_displayed', $was_shown ? 1 : 0);
$this->settings->set('woocommerce_import_screen_displayed', $was_shown ? 1 : 0);
return $this;
}