lib/pigeon/engine.rb
def trigger_task(task_name = nil, &block)
    task_lock(task_name || block) do
      block_given? ? yield : send(task_name)
    end
  end
# This acts as a lock to prevent over-lapping calls to the same method.
# While the first call is in progress, all subsequent calls will be ignored.
This acts as a lock to prevent over-lapping calls to the same method.
While the first call is in progress, all subsequent calls will be ignored.
This acts as a lock to prevent over - lapping calls to the same method . While the first call is in progress all subsequent calls will be ignored .
def trigger_task(task_name = nil, &block)
    task_lock(task_name || block) do
      block_given? ? yield : send(task_name)
    end
  end
def trigger_task ( task_name = nil , & block ) task_lock ( task_name || block ) do block_given? ? yield : send ( task_name ) end end
This acts as a lock to prevent over-lapping calls to the same method.
This acts as a lock to prevent over - lapping calls to the same method .
task_name
block