From 93a90cd9c364680cfcc4c1d1ada13efed233e5bd Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Tue, 29 Nov 2016 15:32:25 +0100 Subject: Delete statuses asynchronously but provide instant feedback in the API --- app/workers/removal_worker.rb | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 app/workers/removal_worker.rb (limited to 'app/workers') diff --git a/app/workers/removal_worker.rb b/app/workers/removal_worker.rb new file mode 100644 index 000000000..7470c54f5 --- /dev/null +++ b/app/workers/removal_worker.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +class RemovalWorker + include Sidekiq::Worker + + def perform(status_id) + RemoveStatusService.new.call(Status.find(status_id)) + end +end \ No newline at end of file -- cgit