diff options
author | Luke Kanies <luke@madstop.com> | 2009-12-21 14:03:53 -0800 |
---|---|---|
committer | James Turnbull <james@lovedthanlost.net> | 2010-01-18 23:21:52 +1100 |
commit | 282b4b3b469a5b40a671f99e23f7382a433ca944 (patch) | |
tree | 4cf4e25787e67e1563e57ab1b90d61787d3d972f /lib/puppet | |
parent | 66a3e6a54df59aafa107f5ec5697ad1a6d4b7e56 (diff) | |
download | puppet-282b4b3b469a5b40a671f99e23f7382a433ca944.tar.gz puppet-282b4b3b469a5b40a671f99e23f7382a433ca944.tar.xz puppet-282b4b3b469a5b40a671f99e23f7382a433ca944.zip |
Removing some unneeded validation code from Transaction.new
Signed-off-by: Luke Kanies <luke@madstop.com>
Diffstat (limited to 'lib/puppet')
-rw-r--r-- | lib/puppet/transaction.rb | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/lib/puppet/transaction.rb b/lib/puppet/transaction.rb index e132b7238..21aa7a36d 100644 --- a/lib/puppet/transaction.rb +++ b/lib/puppet/transaction.rb @@ -417,14 +417,8 @@ class Transaction # this should only be called by a Puppet::Type::Component resource now # and it should only receive an array - def initialize(resources) - if resources.is_a?(Puppet::Resource::Catalog) - @catalog = resources - elsif resources.is_a?(Puppet::SimpleGraph) - raise "Transactions should get catalogs now, not SimpleGraph" - else - raise "Transactions require catalogs" - end + def initialize(catalog) + @catalog = resources @resourcemetrics = { :total => @catalog.vertices.length, |