add   get  '/chatroom' => 'chats#room', :as => :chat to config/routes.rb