Fix modules with "return" outside of function
[MAILPOET-1829]
This commit is contained in:
@@ -3,10 +3,7 @@ import jQuery from 'jquery';
|
||||
import mp from 'mailpoet';
|
||||
|
||||
var MailPoet = mp;
|
||||
if (jQuery('#mailpoet_settings').length === 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (jQuery('#mailpoet_settings').length > 0) {
|
||||
MailPoet.Router = new (Backbone.Router.extend({
|
||||
routes: {
|
||||
'': 'defaultRoute',
|
||||
@@ -79,3 +76,4 @@ import mp from 'mailpoet';
|
||||
jQuery(document).ready(function () { // eslint-disable-line func-names
|
||||
if (!Backbone.History.started) Backbone.history.start();
|
||||
});
|
||||
}
|
||||
|
@@ -3,15 +3,15 @@ import jQuery from 'jquery';
|
||||
import MailPoet from 'mailpoet';
|
||||
import Handlebars from 'handlebars';
|
||||
|
||||
if (!jQuery('#mailpoet_subscribers_export').length) {
|
||||
return;
|
||||
}
|
||||
jQuery(document).ready(function documentReady() {
|
||||
var segmentsContainerElement;
|
||||
var subscriberFieldsContainerElement;
|
||||
var nextStepButton;
|
||||
var renderSegmentsAndFields;
|
||||
var subscribersExportTemplate;
|
||||
if (!jQuery('#mailpoet_subscribers_export').length) {
|
||||
return;
|
||||
}
|
||||
if (!window.exportData.segments) {
|
||||
return;
|
||||
}
|
||||
|
Reference in New Issue
Block a user