User after_commit in stead of after_save
This commit is contained in:
@@ -32,7 +32,7 @@ module Dunlop::SourceFileModel
|
||||
event(:failed) { transition any => :failed }
|
||||
end
|
||||
|
||||
after_create { autoload! }
|
||||
after_commit { autoload! }
|
||||
|
||||
self::Job = Class.new "#{name.deconstantize}::ApplicationJob".constantize do
|
||||
def perform(source_file_id)
|
||||
|
||||
Reference in New Issue
Block a user