diff --git a/client/src/components/manageProjects/createNewEvent.js b/client/src/components/manageProjects/createNewEvent.js index f29f250fc..04df044b3 100644 --- a/client/src/components/manageProjects/createNewEvent.js +++ b/client/src/components/manageProjects/createNewEvent.js @@ -7,7 +7,7 @@ import validateEventForm from './utilities/validateEventForm'; import EventForm from './eventForm'; const CreateNewEvent = ({ - projectName, + projectToEdit, projectID, createNewRecurringEvent, setEventAlert, @@ -72,7 +72,7 @@ const CreateNewEvent = ({ // Handle submission of new recurring event form const handleFormSubmit = async () => { - const errors = validateEventForm(formValues); + const errors = validateEventForm(formValues, projectToEdit); if (!errors) { handleEventCreate(); setFormValues(initialFormValues); diff --git a/client/src/components/manageProjects/editMeetingTimes.js b/client/src/components/manageProjects/editMeetingTimes.js index 7c27edbd9..67beceab0 100644 --- a/client/src/components/manageProjects/editMeetingTimes.js +++ b/client/src/components/manageProjects/editMeetingTimes.js @@ -8,6 +8,7 @@ import validateEventForm from './utilities/validateEventForm'; // This component displays current meeting times for selected project and offers the option to edit those times. const EditMeetingTimes = ({ + projectToEdit, selectedEvent, setEventAlert, setSelectedEvent, @@ -21,7 +22,7 @@ const EditMeetingTimes = ({ startTimeOriginal, durationOriginal ) => async () => { - const errors = validateEventForm(values); + const errors = validateEventForm(values, projectToEdit); if (!errors) { let theUpdatedEvent = {}; diff --git a/client/src/components/manageProjects/editProject.js b/client/src/components/manageProjects/editProject.js index f64cb3931..cd8197f89 100644 --- a/client/src/components/manageProjects/editProject.js +++ b/client/src/components/manageProjects/editProject.js @@ -61,6 +61,7 @@ const EditProject = ({