module Delayed
  class Plugin
    class_inheritable_accessor :callback_block

    def self.callbacks(&block)
      self.callback_block = block
    end
    
    def initialize
      self.class.callback_block.call(Delayed::Worker.lifecycle) if self.class.callback_block
    end
  end
end
module Delayed
  class Plugin
    class_attribute :callback_block

    def self.callbacks(&block)
      self.callback_block = block
    end

    def initialize
      self.class.callback_block.call(Delayed::Worker.lifecycle) if self.class.callback_block
    end
  end
end
Change class_inheritable_accessor to class_attribute in Delayed::Plugin
Change class_inheritable_accessor to class_attribute in Delayed::Plugin