Rails une escopos

class Answer < ActiveRecord::Base
belongs_to
:user
belongs_to
:question
scope
:user_answers, -> { where (user_id: current_user.id) }
scope
:user_answers_with_questions, -> { joins(:questions) & Answer.user_answers }
end