X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/dcfe326f6515cc7aeb9c02b7536e69863c60cd01..79bda7a8edab5b3eb7e2feb13c31228c1ec2c219:/app/controllers/api/traces_controller.rb diff --git a/app/controllers/api/traces_controller.rb b/app/controllers/api/traces_controller.rb index 47dd152a3..5e95892e1 100644 --- a/app/controllers/api/traces_controller.rb +++ b/app/controllers/api/traces_controller.rb @@ -44,6 +44,7 @@ module Api if trace.user == current_user trace.visible = false trace.save! + TraceDestroyerJob.perform_later(trace) if Settings.trace_use_job_queue head :ok else @@ -84,6 +85,7 @@ module Api trace = do_create(params[:file], tags, description, visibility) if trace.id + TraceImporterJob.perform_later(@trace) if Settings.trace_use_job_queue render :plain => trace.id.to_s elsif trace.valid? head :internal_server_error