Fix error when uploading malformed CSV import (#19509)
This commit is contained in:
@ -26,6 +26,8 @@ class ImportValidator < ActiveModel::Validator
|
||||
when 'following'
|
||||
validate_following_import(import, row_count)
|
||||
end
|
||||
rescue CSV::MalformedCSVError
|
||||
import.errors.add(:data, :malformed)
|
||||
end
|
||||
|
||||
private
|
||||
|
Reference in New Issue
Block a user