Commit 70c63620 by Kálmán Viktor

request: fix not changed reason check

parent a2e073ef
Pipeline #71 passed with stage
in 0 seconds
...@@ -73,8 +73,11 @@ class InitialFromFileMixin(object): ...@@ -73,8 +73,11 @@ class InitialFromFileMixin(object):
) )
def clean_message(self): def clean_message(self):
def comp(x):
return "".join(x.strip().splitlines())
message = self.cleaned_data['message'] message = self.cleaned_data['message']
if message.strip() == self.initial['message'].strip(): if comp(message) == comp(self.initial['message']):
raise ValidationError(_("Fill in the message."), code="invalid") raise ValidationError(_("Fill in the message."), code="invalid")
return message.strip() return message.strip()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment