aboutsummaryrefslogtreecommitdiffstats
path: root/app/controllers/general_controller.rb
diff options
context:
space:
mode:
authorGareth Rees <gareth@mysociety.org>2014-09-15 16:46:34 +0100
committerGareth Rees <gareth@mysociety.org>2014-09-15 16:46:34 +0100
commit6946c4b31be38b30820faed5ca782e5ad68c23d0 (patch)
tree4a12b8cfdbbc35dca0e45235a848c5e41ba9da1f /app/controllers/general_controller.rb
parent6c9e18c77efcb718dc4bcc4ef9dfc4b5bd64991d (diff)
parentc6fc4e7b317a8ee89d7c8edd5c1ad3b8c34f6ebc (diff)
Merge branch 'empty_blog' into rails-3-develop
Diffstat (limited to 'app/controllers/general_controller.rb')
-rw-r--r--app/controllers/general_controller.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/controllers/general_controller.rb b/app/controllers/general_controller.rb
index 158492eb2..2c8abbaf4 100644
--- a/app/controllers/general_controller.rb
+++ b/app/controllers/general_controller.rb
@@ -32,7 +32,7 @@ class GeneralController < ApplicationController
if !content.empty?
@data = XmlSimple.xml_in(content)
@channel = @data['channel'][0]
- @blog_items = @channel['item']
+ @blog_items = @channel.fetch('item') { [] }
@feed_autodetect = [{:url => @feed_url, :title => "#{site_name} blog"}]
end
end