These are chat archives for erikras/redux-form

15th
Sep 2017
MVS Teja
@MVSTEJA
Sep 15 2017 11:02

@erikras , I am unable to submit my form after v5.6.3 upgradde for react16, could you provide a suggestion as to what caused this ?.

I am using fieldarrays, this way

if (fieldValues.courses && fieldValues.courses.length > 0) {
const coursesData = ([...fieldValues.courses]);

    coursesData.forEach((course, courseIndex) => {
        const _error = {};

        if (!course || !course.courseName) {
            errors.courses = errors.courses || [];
            _error.courseName = 'Required';
            errors.courses[courseIndex] = _error;
        }
    });
    console.log(courseArrayErrors.length > 0);
}
return errors;
i am sumhow having _error in onsubmit failed
with error : Object {courses: Array(1)}
courses
:
Array(1)
0
:
Object
courseName
:
"Required"
proto
:
Object
_error
:
Object
proto
:
Object
length
:
1
proto
:
Array(0)
proto
:
Object
Without error :-
Object {courses: Object}
courses
:
Object
_error
:
Object