Skip to content

Commit

Permalink
Added initialize by, failing on non existing projects
Browse files Browse the repository at this point in the history
  • Loading branch information
tomasdrga committed Dec 9, 2024
1 parent bcd551c commit 643a4ec
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/jobs/sync_all_topics_job.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def process_row(row, indices, sync_all)


if project_metais_code.present?
project = Project.find_by(id: project_id)
project = Project.find_or_initialize_by(id: project_id)
project.metais_code = project_metais_code
project.save!
end
Expand Down

0 comments on commit 643a4ec

Please sign in to comment.