提交 eeb9fda8 编写于 作者: J Jan Habermann

[ActionCable] remove not needed protected call and newlines

上级 0c973c39
......@@ -48,11 +48,9 @@ class Base
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 @@ def beat
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 @@ def cookies
request.cookie_jar
end
protected
attr_reader :websocket
attr_reader :message_buffer
......@@ -170,7 +165,6 @@ def on_close
disconnect if respond_to?(:disconnect)
end
def allow_request_origin?
return true if server.config.disable_request_forgery_protection
......@@ -193,7 +187,6 @@ def respond_to_invalid_request
[ 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,
......
......@@ -49,7 +49,6 @@ def perform_action(data)
find(data).perform_action ActiveSupport::JSON.decode(data['data'])
end
def identifiers
subscriptions.keys
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册