lib/pigeon/task.rb in pigeon-0.5.0 vs lib/pigeon/task.rb in pigeon-0.5.1

- old
+ new

@@ -111,11 +111,11 @@ send(state_method) end end rescue Object => e - exeption_received(e) + exception_received(e) ensure after_state(state) if (terminate) self.after_finished @@ -153,14 +153,14 @@ # This allows a block to be executed in the main event thread where it is # strictly required. Any exceptions generated by the block will be captured # and will cause the task to transition to the failed state. def execute_in_main_thread - @engine.schedule do + @engine.execute_in_main_thread do begin yield rescue Object => e - exeption_received(e) + exception_received(e) end end end # Called just after the task is initialized.