From cc8220dde80c64027151a065f3dcc7f34a72f0af Mon Sep 17 00:00:00 2001
From: Jean-Philippe Lang <jp_lang@yahoo.fr>
Date: Wed, 7 Nov 2007 21:21:12 +0000
Subject: [PATCH] Fixed: error when sorting the messages if there's only one
 board for the project.

git-svn-id: http://redmine.rubyforge.org/svn/trunk@890 e93f8b46-1217-0410-a6f0-8f06a7374b81
---
 app/controllers/boards_controller.rb | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/app/controllers/boards_controller.rb b/app/controllers/boards_controller.rb
index 2a90e9857..3a8b021a3 100644
--- a/app/controllers/boards_controller.rb
+++ b/app/controllers/boards_controller.rb
@@ -32,7 +32,6 @@ class BoardsController < ApplicationController
     if @boards.size == 1
       @board = @boards.first
       show
-      render :action => 'show'
     end
   end
 
@@ -46,7 +45,7 @@ class BoardsController < ApplicationController
                                   :include => [:author, {:last_reply => :author}],
                                   :limit  =>  @topic_pages.items_per_page,
                                   :offset =>  @topic_pages.current.offset
-    render :action => 'show', :layout => false if request.xhr?
+    render :action => 'show', :layout => !request.xhr?
   end
   
   verify :method => :post, :only => [ :destroy ], :redirect_to => { :action => :index }
-- 
GitLab