From bc3b19678fcba5433b9773611e4b3149cac867f5 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Nov 17 2016 17:11:52 +0000 Subject: Allow clearing the content of a file online, not just editing it Fixes https://pagure.io/pagure/issue/1461 --- diff --git a/pagure/forms.py b/pagure/forms.py index bbdde4b..21f5bf8 100644 --- a/pagure/forms.py +++ b/pagure/forms.py @@ -525,7 +525,7 @@ class NewGroupForm(EditGroupForm): class EditFileForm(PagureForm): """ Form used to edit a file. """ content = wtforms.TextAreaField( - 'content', [wtforms.validators.Required()]) + 'content', [wtforms.validators.Optional()]) commit_title = wtforms.TextField( 'Title', [wtforms.validators.Required()]) commit_message = wtforms.TextAreaField(