Skip to content

Commit

Permalink
adding null check to external-posts.rb to avoid parsing failure (alsh…
Browse files Browse the repository at this point in the history
…edivat#2347)

Adjusting issue alshedivat#2343 by adding null check.
  • Loading branch information
amztc34283 authored Apr 16, 2024
1 parent 5a95486 commit 978cb4f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions _plugins/external-posts.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ def generate(site)
site.config['external_sources'].each do |src|
p "Fetching external posts from #{src['name']}:"
xml = HTTParty.get(src['rss_url']).body
return if xml.nil?
feed = Feedjira.parse(xml)
feed.entries.each do |e|
p "...fetching #{e.url}"
Expand Down

0 comments on commit 978cb4f

Please sign in to comment.