FIX: Don't enqueue topics if the user can't create them

Co-authored-by: Vinoth Kannan <vinothkannan@vinkas.com>
This commit is contained in:
Régis Hanol
2018-11-09 18:24:28 +01:00
parent 00ad6e8e37
commit 6b51d84dc5
4 changed files with 30 additions and 5 deletions

View File

@ -994,6 +994,7 @@ module Email
end
raise TooShortPost
end
raise InvalidPost, errors.join("\n") if result.errors.any?
if result.post