diff options
| author | Brice Figureau <brice-puppet@daysofwonder.com> | 2009-09-10 21:30:42 +0200 |
|---|---|---|
| committer | James Turnbull <james@lovedthanlost.net> | 2009-09-16 11:45:58 +1000 |
| commit | 577a45b45711942f71c31ff2db0c7fbcd82e1b1d (patch) | |
| tree | fa7f44454490e5f7140ee43365e4a68f1b8a0364 /lib | |
| parent | d2d7070fb614840db56ca3672548bf5c58a3e4f0 (diff) | |
| download | puppet-577a45b45711942f71c31ff2db0c7fbcd82e1b1d.tar.gz puppet-577a45b45711942f71c31ff2db0c7fbcd82e1b1d.tar.xz puppet-577a45b45711942f71c31ff2db0c7fbcd82e1b1d.zip | |
Fix #2622 - Puppetdoc in single manifest to console is broken
After the LoadedCode refactoring I forgot to update this (mostly)
unused part of puppetdoc which unfortunately is not covered
by unit tests.
This commit fixes this issue.
Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/puppet/util/rdoc.rb | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/puppet/util/rdoc.rb b/lib/puppet/util/rdoc.rb index a18fa1b96..4edbf06a6 100644 --- a/lib/puppet/util/rdoc.rb +++ b/lib/puppet/util/rdoc.rb @@ -49,13 +49,15 @@ module Puppet::Util::RDoc # of a manifest def output(file, ast) astobj = [] - ast[:nodes].each do |name, k| + ast.nodes.each do |name, k| astobj << k if k.file == file end - ast[:classes].each do |name, k| + + ast.hostclasses.each do |name,k| astobj << k if k.file == file end - ast[:definitions].each do |name, k| + + ast.definitions.each do |name, k| astobj << k if k.file == file end astobj.sort! {|a,b| a.line <=> b.line }.each do |k| |
