From 2a8fbb4063de625e008e85b4ef0030e4da2d3448 Mon Sep 17 00:00:00 2001 From: Henrik Levkowetz Date: Sat, 10 May 2014 10:39:33 +0000 Subject: [PATCH] Added validation of successful draft title extraction on draft submission upload, to avoid a later exception when trying to store draft information for a draft with a null title. - Legacy-Id: 7730 --- ietf/submit/forms.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ietf/submit/forms.py b/ietf/submit/forms.py index fc941f748..9f04313a0 100644 --- a/ietf/submit/forms.py +++ b/ietf/submit/forms.py @@ -107,6 +107,9 @@ class UploadForm(forms.Form): if not self.parsed_draft.filename: raise forms.ValidationError("Draft parser could not extract a valid draft name from the .txt file") + if not self.parsed_draft.get_title(): + raise forms.ValidationError("Draft parser could not extract a valid title from the .txt file") + # check group self.group = self.deduce_group()