From ab7b8ca8d6c5da5e9f0fe0ceae84dc8eadb6fdf7 Mon Sep 17 00:00:00 2001 From: francis Date: Fri, 9 May 2008 01:02:32 +0000 Subject: Make it work when no title during creation. --- app/models/info_request.rb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'app/models/info_request.rb') diff --git a/app/models/info_request.rb b/app/models/info_request.rb index af5a3b27b..d3285116c 100644 --- a/app/models/info_request.rb +++ b/app/models/info_request.rb @@ -21,7 +21,7 @@ # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: francis@mysociety.org; WWW: http://www.mysociety.org/ # -# $Id: info_request.rb,v 1.105 2008-05-09 01:00:42 francis Exp $ +# $Id: info_request.rb,v 1.106 2008-05-09 01:02:32 francis Exp $ require 'digest/sha1' require File.join(File.dirname(__FILE__),'../../vendor/plugins/acts_as_xapian/lib/acts_as_xapian') @@ -109,7 +109,10 @@ public # Remove spaces from ends (for when used in emails etc.) def title title = read_attribute(:title) - title.strip + if title + title.strip! + end + return title end # Email which public body should use to respond to request. This is in -- cgit v1.2.3