I need an ActiveRecord query to find conversations for current_user and any another user
Conversations can have many users. I need to set users ids in that query(it can be two or more users).
class Conversation < ActiveRecord::Base
has_many :users
end
class User < ActiveRecord::Base
belongs_to :conversations
end
You can join and put the query as a hash
or