X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/414c4b2c36bc78ece037e30bf8139b129abcd280..947a41edee95df9e75cce0452277e2a00a8b5fa5:/app/controllers/traces_controller.rb diff --git a/app/controllers/traces_controller.rb b/app/controllers/traces_controller.rb index 253bc4160..2e4997877 100644 --- a/app/controllers/traces_controller.rb +++ b/app/controllers/traces_controller.rb @@ -127,6 +127,7 @@ class TracesController < ApplicationController flash[:notice] = t ".trace_uploaded" flash[:warning] = t ".traces_waiting", :count => current_user.traces.where(:inserted => false).count if current_user.traces.where(:inserted => false).count > 4 + TraceImporterJob.perform_later(@trace) if TRACE_USE_JOB_QUEUE redirect_to :action => :index, :display_name => current_user.display_name else flash[:error] = t("traces.create.upload_failed") if @trace.valid? @@ -210,6 +211,7 @@ class TracesController < ApplicationController trace.visible = false trace.save flash[:notice] = t ".scheduled_for_deletion" + TraceDestroyerJob.perform_later(trace) if TRACE_USE_JOB_QUEUE redirect_to :action => :index, :display_name => trace.user.display_name end rescue ActiveRecord::RecordNotFound