Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,10 @@ function CreateEventModal({ isOpen, toggle }) {
newErrors.maxAttendees = 'Max attendees must be at least 1';
}

if (formData.maxAttendees < 0 || !Number.isInteger(formData.maxAttendees)) {
newErrors.maxAttendees = 'Max Attendees must be a Positive Integer';
}

// Validate that end time is after start time
if (formData.startTime && formData.endTime) {
const start = moment(`${formData.date} ${formData.startTime}`, 'YYYY-MM-DD HH:mm');
Expand Down
Loading