aboutsummaryrefslogtreecommitdiffstats
path: root/actioncable/lib/action_cable
diff options
context:
space:
mode:
authorJan Habermann <jan@habermann24.com>2015-12-25 14:08:50 +0100
committerJan Habermann <jan@habermann24.com>2015-12-25 14:08:50 +0100
commiteeb9fda8e27be6c5c0ff988e0cde2b3a489a2dca (patch)
tree1447f2031ca2269533bcf9cce4f9ab0e6294472b /actioncable/lib/action_cable
parent0c973c39200b0708461f7ffaa27b53798f500d5e (diff)
downloadrails-eeb9fda8e27be6c5c0ff988e0cde2b3a489a2dca.tar.gz
rails-eeb9fda8e27be6c5c0ff988e0cde2b3a489a2dca.tar.bz2
rails-eeb9fda8e27be6c5c0ff988e0cde2b3a489a2dca.zip
[ActionCable] remove not needed protected call and newlines
Diffstat (limited to 'actioncable/lib/action_cable')
-rw-r--r--actioncable/lib/action_cable/connection/base.rb9
-rw-r--r--actioncable/lib/action_cable/connection/subscriptions.rb1
2 files changed, 1 insertions, 9 deletions
diff --git a/actioncable/lib/action_cable/connection/base.rb b/actioncable/lib/action_cable/connection/base.rb
index f7b18a85ae..977856d656 100644
--- a/actioncable/lib/action_cable/connection/base.rb
+++ b/actioncable/lib/action_cable/connection/base.rb
@@ -48,11 +48,9 @@ module ActionCable
include InternalChannel
include Authorization
- attr_reader :server, :env, :subscriptions
+ attr_reader :server, :env, :subscriptions, :logger
delegate :worker_pool, :pubsub, to: :server
- attr_reader :logger
-
def initialize(server, env)
@server, @env = server, env
@@ -123,7 +121,6 @@ module ActionCable
transmit ActiveSupport::JSON.encode(identifier: ActionCable::INTERNAL[:identifiers][:ping], message: Time.now.to_i)
end
-
protected
# The request that initiated the WebSocket connection is available here. This gives access to the environment, cookies, etc.
def request
@@ -138,8 +135,6 @@ module ActionCable
request.cookie_jar
end
-
- protected
attr_reader :websocket
attr_reader :message_buffer
@@ -170,7 +165,6 @@ module ActionCable
disconnect if respond_to?(:disconnect)
end
-
def allow_request_origin?
return true if server.config.disable_request_forgery_protection
@@ -193,7 +187,6 @@ module ActionCable
[ 404, { 'Content-Type' => 'text/plain' }, [ 'Page not found' ] ]
end
-
# Tags are declared in the server but computed in the connection. This allows us per-connection tailored tags.
def new_tagged_logger
TaggedLoggerProxy.new server.logger,
diff --git a/actioncable/lib/action_cable/connection/subscriptions.rb b/actioncable/lib/action_cable/connection/subscriptions.rb
index 65d6634bb0..d7f95e6a62 100644
--- a/actioncable/lib/action_cable/connection/subscriptions.rb
+++ b/actioncable/lib/action_cable/connection/subscriptions.rb
@@ -49,7 +49,6 @@ module ActionCable
find(data).perform_action ActiveSupport::JSON.decode(data['data'])
end
-
def identifiers
subscriptions.keys
end