Fix ES5 semi eslint rule [MAILPOET-1030]

This commit is contained in:
stoletniy
2017-09-04 09:22:52 +03:00
committed by pavel-mailpoet
parent e347fc74a2
commit efece061d0
6 changed files with 17 additions and 18 deletions

View File

@@ -47,7 +47,6 @@
"no-mixed-operators": 0,
"eqeqeq": 0,
"space-in-parens": 0,
"semi": 0,
"max-len": 0,
"no-trailing-spaces": 0,
"global-require": 0,

View File

@@ -38,7 +38,7 @@ function exportMixpanel(mp) {
function trackCachedEvents() {
eventsCache.map(function (event) {
if (window.mailpoet_analytics_enabled || event.forced) {
window.mixpanel.track(event.name, event.data)
window.mixpanel.track(event.name, event.data);
}
});
}

View File

@@ -25,14 +25,14 @@ Object.extend(document, (function() {
function findWrapper(selector, eventName, handler) {
var c = getWrappersForSelector(selector, eventName);
return c.find(function(wrapper) {
return wrapper.handler === handler
return wrapper.handler === handler;
});
}
function destroyWrapper(selector, eventName, handler) {
var c = getCacheForSelector(selector);
if(!c[eventName]) return false;
var wrapper = findWrapper(selector, eventName, handler)
var wrapper = findWrapper(selector, eventName, handler);
c[eventName] = c[eventName].without(wrapper);
return wrapper;
}
@@ -78,7 +78,7 @@ Object.extend(document, (function() {
}
return document;
}
}
};
})());
var Observable = (function() {
@@ -101,7 +101,7 @@ var Observable = (function() {
function getWrapper(handler, klass) {
return function(event) {
return handler.call(new klass(this), event, event.memo);
}
};
}
function onDomLoad(selector, klass) {
@@ -126,7 +126,7 @@ var Observable = (function() {
});
delete this.handlers[selector];
}
}
};
})();
// override droppables

View File

@@ -12,7 +12,7 @@ define('mp2migrator', ['mailpoet', 'jquery'], function(mp, jQuery) {
clearTimeout(MailPoet.MP2Migrator.displayLogs_timeout);
clearTimeout(MailPoet.MP2Migrator.updateProgressbar_timeout);
clearTimeout(MailPoet.MP2Migrator.update_wordpress_info_timeout);
setTimeout(MailPoet.MP2Migrator.updateDisplay, 1000)
setTimeout(MailPoet.MP2Migrator.updateDisplay, 1000);
},
stopLogger: function () {

View File

@@ -121,7 +121,7 @@ define([
this.showChildView('toolsRegion', this.toolsView);
this.showChildView('icons', new Module.SocialIconCollectionView({
collection: this.model.get('icons')
}))
}));
}
});

View File

@@ -169,7 +169,7 @@ define(
setTimeout(function () {
uploadElement.parse({
config: parseCSV(true)
})
});
}, 10);
}
});
@@ -433,7 +433,7 @@ define(
MailPoet.Notice.error(errorNotice);
}
}
}
};
}
});
@@ -573,14 +573,14 @@ define(
toggleNextStepButton('on');
}
}
})
});
}
jQuery('.mailpoet_create_segment').click(function() {
MailPoet.Modal.popup({
title: MailPoet.I18n.t('addNewList'),
template: jQuery('#new_segment_template').html()
})
});
jQuery('#new_segment_name').keypress(function(e) {
if (e.which == 13) {
jQuery('#new_segment_process').click();
@@ -607,7 +607,7 @@ define(
var selected_values = segmentSelectElement.val();
if (selected_values === null) {
selected_values = [response.data.id]
selected_values = [response.data.id];
} else {
selected_values.push(response.data.id);
}
@@ -784,7 +784,7 @@ define(
templateSelection: function (item) {
return item.name;
}
})
});
});
jQuery(selectElement).data('column-id', new_column_data.id);
jQuery(selectElement).data('validation-rule', false);
@@ -893,11 +893,11 @@ define(
}
else {
for (var format in allowedDateFormats) {
var testedFormat = allowedDateFormats[format]
var testedFormat = allowedDateFormats[format];
if (Moment(firstRowData, testedFormat, true).isValid()) {
var validationRule = (typeof(testedFormat) === 'function') ?
'datetime' :
testedFormat
testedFormat;
// set validation on the column element
jQuery(matchedColumn.element).data('validation-rule', validationRule);
break;
@@ -1038,7 +1038,7 @@ define(
}
});
batchNumber++;
})
});
});
queue.run();