Remove redundant code
[MAILPOET-1808]
This commit is contained in:
@@ -6,28 +6,13 @@ import jQuery from 'jquery';
|
|||||||
import 'asyncqueue';
|
import 'asyncqueue';
|
||||||
import MailPoet from 'mailpoet';
|
import MailPoet from 'mailpoet';
|
||||||
import Handlebars from 'handlebars';
|
import Handlebars from 'handlebars';
|
||||||
import Papa from 'papaparse';
|
|
||||||
import Moment from 'moment';
|
import Moment from 'moment';
|
||||||
import sanitizeCSVData from './import/sanitize_csv_data.jsx';
|
|
||||||
import StepInputValidation from './import/step_input_validation.jsx';
|
import StepInputValidation from './import/step_input_validation.jsx';
|
||||||
import StepMethodSelection from './import/step_method_selection.jsx';
|
import StepMethodSelection from './import/step_method_selection.jsx';
|
||||||
import StepResults from './import/step_results.jsx';
|
import StepResults from './import/step_results.jsx';
|
||||||
|
|
||||||
const SUBSCRIBERS_LIMIT_FOR_VALIDATION = 500;
|
const SUBSCRIBERS_LIMIT_FOR_VALIDATION = 500;
|
||||||
|
|
||||||
function getMethodSelectionNextStepLink(importData) {
|
|
||||||
if (importData === undefined) {
|
|
||||||
return 'step_data_manipulation';
|
|
||||||
}
|
|
||||||
if (importData.subscribersCount === undefined) {
|
|
||||||
return 'step_data_manipulation';
|
|
||||||
}
|
|
||||||
if (importData.subscribersCount < SUBSCRIBERS_LIMIT_FOR_VALIDATION) {
|
|
||||||
return 'step_data_manipulation';
|
|
||||||
}
|
|
||||||
return 'step_input_validation';
|
|
||||||
}
|
|
||||||
|
|
||||||
function getDataManipulationPreviousStepLink(importData) {
|
function getDataManipulationPreviousStepLink(importData) {
|
||||||
if (importData === undefined) {
|
if (importData === undefined) {
|
||||||
return 'step_method_selection';
|
return 'step_method_selection';
|
||||||
|
Reference in New Issue
Block a user