Fix CSV import & contestant deletion

This commit is contained in:
sto
2025-06-19 10:33:36 +02:00
parent f78a082ad3
commit 4645b45f5d
4 changed files with 9 additions and 8 deletions

View File

@@ -32,7 +32,7 @@ class CsvImport < ApplicationRecord
end
begin
csv = CSV.read(attachment_changes["file"].attachable.path, col_sep: separator)
csv = CSV.read(attachment_changes["file"].attachable.path, col_sep: separator_for_database)
errors.add(:file, :empty) if csv.count < 1 || (csv.count == 1 && csv[0].count == 1 && csv[0][0] == "")
rescue CSV::MalformedCSVError => e