diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2015-06-21 20:25:53 +0200 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2015-06-21 20:25:53 +0200 |
commit | a4a68c2aff6b9aa114b0309d008e7f4180169bd4 (patch) | |
tree | 4f70d94b7c97a729f3154246f762425c52660ff9 /lib/action_cable | |
parent | 6ae798fc842c65011528175136fcda85d95ab16c (diff) | |
download | rails-a4a68c2aff6b9aa114b0309d008e7f4180169bd4.tar.gz rails-a4a68c2aff6b9aa114b0309d008e7f4180169bd4.tar.bz2 rails-a4a68c2aff6b9aa114b0309d008e7f4180169bd4.zip |
Match transmit. No need to qualify _data
Diffstat (limited to 'lib/action_cable')
-rw-r--r-- | lib/action_cable/connection/base.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/action_cable/connection/base.rb b/lib/action_cable/connection/base.rb index 6973848589..4a67167bac 100644 --- a/lib/action_cable/connection/base.rb +++ b/lib/action_cable/connection/base.rb @@ -44,7 +44,7 @@ module ActionCable if message.is_a?(String) if @accept_messages - worker_pool.async.invoke(self, :receive_data, message) + worker_pool.async.invoke(self, :receive, message) else @pending_messages << message end @@ -64,7 +64,7 @@ module ActionCable end end - def receive_data(data_in_json) + def receive(data_in_json) if websocket_alive? data = ActiveSupport::JSON.decode data_in_json @@ -117,7 +117,7 @@ module ActionCable subscribe_to_internal_channel @accept_messages = true - worker_pool.async.invoke(self, :receive_data, @pending_messages.shift) until @pending_messages.empty? + worker_pool.async.invoke(self, :receive, @pending_messages.shift) until @pending_messages.empty? end def close_connection |