Fixed: SplitDateTime Widgets always complains about the date/time format.

This commit is contained in:
2017-11-05 21:58:12 +01:00
parent 50b520caae
commit f571f44995
3 changed files with 4 additions and 6 deletions

View File

@@ -112,7 +112,7 @@ class Event(models.Model):
return "New Event Model"
def clean(self):
if self.end < self.start:
if self.end and self.end < self.start:
raise ValidationError({
'end': _("A event can't end before it had started")
})