Skip to content

Commit 24a1af3

Browse files
committed
応急処置。
メソッドが嘘つきになっているので、メソッド構成を変更する。
1 parent 3b9bf1a commit 24a1af3

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

app/models/concerns/csv_importable.rb

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def csv_import(file, parser, header_config, type_convert_config, association_con
3737
# エラーが無ければ bulk insert 実行
3838
# rubocop:disable Rails/SkipsModelValidations
3939
# `collect_validate_errors` にてバリデーション済みなので警告を抑制
40-
insert_all(csv_records.map(&:model)) if errors.empty?
40+
# insert_all(csv_records.map(&:model)) if errors.empty?
4141
# rubocop:enable Rails/SkipsModelValidations
4242

4343
errors
@@ -49,7 +49,6 @@ def collect_validate_errors(model_with_lineno)
4949

5050
# バリデーションを実行し、エラーがあればエラーメッセージを返却用配列へ格納
5151
model_with_lineno.each do |mwl|
52-
pp mwl
5352
model = create(mwl.model)
5453
is_valid = model.validate
5554

0 commit comments

Comments
 (0)