Commit e34fa3e9 authored by Jonathan Riddell's avatar Jonathan Riddell 🛶

remove some nodes

parent f201037a
......@@ -53,9 +53,8 @@ class MetaInfoUpdater
component.add_child("<releases><release version='#{@version}' date='#{date}'/></releases>")
end
if @releases_to_show > 0
xpath = releases.xpath("//release")
if xpath.length > @releases_to_show
puts "XXX Too many releases!!"
if releases.children.length > @releases_to_show
releases.children = releases.children[-@releases_to_show,@releases_to_show]
end
end
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment