diff options
Diffstat (limited to 'lib/action_cable')
-rw-r--r-- | lib/action_cable/connection/identification.rb | 2 | ||||
-rw-r--r-- | lib/action_cable/server/connections.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/action_cable/connection/identification.rb b/lib/action_cable/connection/identification.rb index 4e9beac058..95863795dd 100644 --- a/lib/action_cable/connection/identification.rb +++ b/lib/action_cable/connection/identification.rb @@ -22,7 +22,7 @@ module ActionCable # Return a single connection identifier that combines the value of all the registered identifiers into a single gid. def connection_identifier - if @connection_identifier.blank? + unless defined? @connection_identifier @connection_identifier = connection_gid identifiers.map { |id| instance_variable_get("@#{id}") }.compact end diff --git a/lib/action_cable/server/connections.rb b/lib/action_cable/server/connections.rb index 153cebd710..47dcea8c20 100644 --- a/lib/action_cable/server/connections.rb +++ b/lib/action_cable/server/connections.rb @@ -24,7 +24,7 @@ module ActionCable def setup_heartbeat_timer EM.next_tick do @heartbeat_timer ||= EventMachine.add_periodic_timer(BEAT_INTERVAL) do - EM.next_tick { connections.map &:beat } + EM.next_tick { connections.map(&:beat) } end end end |