Run job hooks after transation commits after create

This commit is contained in:
Grzegorz Bizon 2017-08-23 08:32:44 +02:00
parent 0a2998b319
commit da4c54e4fb
1 changed files with 1 additions and 1 deletions

View File

@ -47,7 +47,7 @@ module Ci
before_destroy { unscoped_project }
after_create do |build|
BuildHooksWorker.perform_async(build.id)
run_after_commit { BuildHooksWorker.perform_async(build.id) }
end
after_commit :update_project_statistics_after_save, on: [:create, :update]