instance method
before_subscribe
Ruby on Rails edge
Since v5.2.8.1Signature
before_subscribe(*methods, &block)
This callback will be triggered before the Base#subscribed method is called.
However, if the subscription is rejected with the Base#reject method in any such callback, the Base#subscribed method will not be called.
Parameters
-
methodsrest -
blockblock
Source
# File actioncable/lib/action_cable/channel/callbacks.rb, line 55
def before_subscribe(*methods, &block)
set_callback(:subscribe, :before, *methods, &block)
end
Defined in actioncable/lib/action_cable/channel/callbacks.rb line 55
· View on GitHub
· Improve this page
· Find usages on GitHub