I have a reduction form and I have a problem with the validation function. And this error occurs only on my cloud servers, on local, I have no problems with this.
Here is the check function:
function validate(values){
const errors = {};
let requiredFields = [
'gender', 'first_name', 'last_name'
];
requiredFields.forEach(field => {
if (!values[field]) {
errors[field] = 'Required';
}
});
return errors;
}
And I call it that:
EditProfileForm = reduxForm({
form: 'editProfile',
validate
})(EditProfileForm);
And even when I run the production code in local, which now just does:
config.plugins.push(new webpack.optimize.UglifyJsPlugin({
mangle: false
})
)
It still works in local mode, only when the code is on the servers, I have a problem.
It sends the action: redux-form / UPDATE_SYNC_ERRORS to infinite, and I have to force Chrome to disable to stop this.
initialValues, , , , DB first_name . , , .
first_name undefined, DB, .
6.4.2
?