Commit aa4cc757 authored by Emma's avatar Emma 😻

fix sql error on empty body

parent 595b1c5d
......@@ -24,7 +24,8 @@ class Comment extends Votable implements BodyInterface {
/**
* @ORM\Column(type="text")
*
* @Assert\NotBlank()
* @Assert\NotBlank(message="The comment must not be empty.")
* @Assert\Regex("/[[:graph:]]/u", message="The comment must not be empty.")
* @Assert\Length(max=10000)
*
* @var string
......
'The comment must not be empty.': 'The comment must not be empty.'
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 to comment