From 31fec273d484f3dd34ca001ae4a63ee7f9059dc1 Mon Sep 17 00:00:00 2001 From: Aaron Stone Date: Sat, 28 Apr 2018 15:35:00 -0700 Subject: [PATCH] Avoid explicitly calling class methods when in class scope --- lib/eventmachine.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/eventmachine.rb b/lib/eventmachine.rb index 6f32c58f0..2d0221831 100644 --- a/lib/eventmachine.rb +++ b/lib/eventmachine.rb @@ -986,7 +986,7 @@ def self.run_deferred_callbacks # do some work during the next_tick. The only mechanism we have from the # ruby side is next_tick itself, although ideally, we'd just drop a byte # on the loopback descriptor. - EM.next_tick {} if exception_raised + next_tick {} if exception_raised end end end @@ -1081,7 +1081,7 @@ def self.spawn_threadpool raise error unless eback @resultqueue << [error, eback] end - EventMachine.signal_loopbreak + signal_loopbreak end end @threadpool << thread @@ -1515,7 +1515,7 @@ def self.event_callback conn_binding, opcode, data else if $! # Bubble user generated errors. @wrapped_exception = $! - EM.stop + stop else raise ConnectionNotBound, "received ConnectionUnbound for an unknown signature: #{conn_binding}" end