diff --git a/lib/action_cable/connection/identification.rb b/lib/action_cable/connection/identification.rb index 246636198b..6c2af04663 100644 --- a/lib/action_cable/connection/identification.rb +++ b/lib/action_cable/connection/identification.rb @@ -10,7 +10,8 @@ module ActionCable class_methods do def identified_by(*identifiers) - self.identifiers += identifiers + Array(identifiers).each { |identifier| attr_accessor identifier } + self.identifiers += identifiers end end