Class: Workarea::IndexHelp

Inherits:
Object
  • Object
show all
Includes:
Sidekiq::CallbacksWorker, Sidekiq::Worker
Defined in:
app/workers/workarea/index_help.rb

Instance Method Summary collapse

Instance Method Details

#perform(id) ⇒ Object



11
12
13
14
15
16
17
# File 'app/workers/workarea/index_help.rb', line 11

def perform(id)
  if article = Help::Article.find(id) rescue nil
    Search::Help.new(article).save
  else
    Search::Help.delete(id)
  end
end