1
0
Fork 0
mirror of https://github.com/endofunky/sidetiq.git synced 2022-11-09 13:53:30 -05:00

Don't get worker class using eval().

This is a left over from a previous API.
This commit is contained in:
Tobias Svensson 2013-02-01 09:35:25 +00:00
parent 7a0cf8fea3
commit f4e39af839

View file

@ -3,10 +3,8 @@ module Sidetiq
module ClassMethods module ClassMethods
def tiq(&block) def tiq(&block)
clock = Sidetiq::Clock.instance clock = Sidetiq::Clock.instance
worker = block.send(:binding).eval('self')
clock.synchronize do clock.synchronize do
clock.schedule_for(worker).instance_eval(&block) clock.schedule_for(self).instance_eval(&block)
end end
end end
end end