-feed_url = url_for(:format => "atom", :tags => params[:tags])

-content_for :rss do
  %link{:rel=>"alternate", :type=>"application/atom+xml", :title => "atom", :href=> url_for(:format => "atom", :tags => params[:tags])}
  %link{:rel=>"alternate", :type=>"application/atom+xml", :title => "atom", :href=> url_for(:format => "atom")}

-if @questions.empty?
  = render "shared/empty", :type => "questions", :url => new_question_path
-else
  -if params[:answers]
    -cache_for(:questions, :answers, current_order.to_s, params[:page].to_i, params[:per_page].to_i) do
      /Answers
      -@questions.each do |question|
        -answer = find_answer(question)
        = render "answers/answer", :question => question, :answer => answer if answer

  -else
    -cache_for(:questions, current_order.to_s, params[:page].to_i, params[:per_page].to_i, @languages.sort) do
      /Questions
      -@questions.each do |question|
        = render "questions/question", :question => question

  = paginate @questions

-feed_url = url_for(:format => "atom", :tags => params[:tags])

-content_for :rss do
  %link{:rel=>"alternate", :type=>"application/atom+xml", :title => "atom", :href=> url_for(:format => "atom", :tags => params[:tags])}
  %link{:rel=>"alternate", :type=>"application/atom+xml", :title => "atom", :href=> url_for(:format => "atom")}

-if @questions.empty?
  = render "shared/empty", :type => "questions", :url => new_question_path
-else
  -if params[:answers]
    -cache_for(:questions, :answers, current_order.to_s, params[:page].to_i, params[:per_page].to_i) do
      /Answers
      -@questions.each do |question|
        -answer = find_answer(question)
        = render "answers/answer", :question => question, :answer => answer if answer

  -else
    -cache_for(:questions, current_order.to_s, params[:page].to_i, params[:per_page].to_i, @languages.sort, params[:unanswered] ? "unanswered" : "" ) do
      /Questions
      -@questions.each do |question|
        = render "questions/question", :question => question

  = paginate @questions

Fix cache for unanswered questions
Fix cache for unanswered questions

Signed-off-by: Jorge H. Cuadrado <f24d0cb14d293fb1f3cb2016ae41425d3291832c@gmail.com>
