diff --git a/app/models/fs/message_draft.rb b/app/models/fs/message_draft.rb index c18c0978..199c3306 100644 --- a/app/models/fs/message_draft.rb +++ b/app/models/fs/message_draft.rb @@ -31,7 +31,12 @@ def self.create_and_validate_with_fs_form(form_files: [], author:, fs_client: Fs form_files.each do |form_file| form_content = form_file.read.force_encoding("UTF-8") - form_information = fs_client.api.parse_form(form_content) + begin + form_information = fs_client.api.parse_form(form_content) + rescue + messages << nil + next + end dic = form_information['subject']&.strip fs_form_identifier = form_information['form_identifier']