diff --git a/anycable-rails.gemspec b/anycable-rails.gemspec index b3b2aa2..21ffe8e 100644 --- a/anycable-rails.gemspec +++ b/anycable-rails.gemspec @@ -19,7 +19,7 @@ Gem::Specification.new do |spec| spec.require_paths = ["lib"] spec.add_dependency "rails", ">= 5" - spec.add_dependency "anycable", "0.6.0.rc1" + spec.add_dependency "anycable", "~> 0.6.0" spec.add_development_dependency "bundler", "~> 1" spec.add_development_dependency "rake", "~> 10.0" diff --git a/lib/anycable/rails.rb b/lib/anycable/rails.rb index e55ee7d..774700d 100644 --- a/lib/anycable/rails.rb +++ b/lib/anycable/rails.rb @@ -8,8 +8,11 @@ module AnyCable # Rails handler for AnyCable module Rails require "anycable/rails/railtie" + # Load Action Cable patches only when running RPC server - require "anycable/rails/actioncable/connection" if defined?(::AnyCable::CLI) + AnyCable.configure_server do + require "anycable/rails/actioncable/connection" + end end end diff --git a/lib/anycable/rails/version.rb b/lib/anycable/rails/version.rb index b1f64b8..95a4ed4 100644 --- a/lib/anycable/rails/version.rb +++ b/lib/anycable/rails/version.rb @@ -2,6 +2,6 @@ module AnyCable module Rails - VERSION = "0.6.0.rc1" + VERSION = "0.6.0" end end