aboutsummaryrefslogtreecommitdiffstats
path: root/app/models
diff options
context:
space:
mode:
Diffstat (limited to 'app/models')
-rw-r--r--app/models/public_body.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/app/models/public_body.rb b/app/models/public_body.rb
index 961fa3cbb..23f71333d 100644
--- a/app/models/public_body.rb
+++ b/app/models/public_body.rb
@@ -284,7 +284,12 @@ class PublicBody < ActiveRecord::Base
def calculated_home_page
# manual override for ones we calculate wrongly
if self.home_page != ''
- return self.home_page
+ # Add standard URL prefix
+ if home_page[0..10] == 'http://www.'
+ return self.home_page
+ else
+ return "http://www.#{self.home_page}"
+ end
end
# extract the domain name from the FOI request email