diff options
author | francis <francis> | 2008-09-03 09:03:56 +0000 |
---|---|---|
committer | francis <francis> | 2008-09-03 09:03:56 +0000 |
commit | bb5fff786a415637132b5b2230afbccd886a26d5 (patch) | |
tree | 4be1185d3efc500ded5b839fd55c9aaead2ffb6d /app/controllers/request_controller.rb | |
parent | 8b40bf24b0e145d5848622e27935ab463ac3da3f (diff) |
Don't let bots crawl search results or similar request pages.
Diffstat (limited to 'app/controllers/request_controller.rb')
-rw-r--r-- | app/controllers/request_controller.rb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/app/controllers/request_controller.rb b/app/controllers/request_controller.rb index dd12a91b5..7614aee73 100644 --- a/app/controllers/request_controller.rb +++ b/app/controllers/request_controller.rb @@ -4,7 +4,7 @@ # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: francis@mysociety.org; WWW: http://www.mysociety.org/ # -# $Id: request_controller.rb,v 1.105 2008-09-02 17:59:39 francis Exp $ +# $Id: request_controller.rb,v 1.106 2008-09-03 09:03:57 francis Exp $ class RequestController < ApplicationController @@ -48,6 +48,11 @@ class RequestController < ApplicationController @info_request = InfoRequest.find_by_url_title(params[:url_title]) @xapian_object = ::ActsAsXapian::Similar.new([InfoRequestEvent], @info_request.info_request_events, :offset => (@page - 1) * @per_page, :limit => @per_page, :collapse_by_prefix => 'request_collapse') + + # Stop robots crawling similar request lists. There is no point them + # doing so. Google bot was going dozens of pages in, and they are slow + # pages to generate, having an impact on server load. + @no_crawl = true end def list |