diff options
| author | Luke Kanies <luke@madstop.com> | 2008-07-04 16:06:02 -0500 |
|---|---|---|
| committer | Luke Kanies <luke@madstop.com> | 2008-07-04 16:06:02 -0500 |
| commit | 61ec332144ad794fae80a16feac543afc014a5f9 (patch) | |
| tree | b62369f37d3d0878ff77e2250907636b060ceb03 /lib | |
| parent | 2863df288150da87a58ce4d938bbcf9a5d841f43 (diff) | |
| download | puppet-61ec332144ad794fae80a16feac543afc014a5f9.tar.gz puppet-61ec332144ad794fae80a16feac543afc014a5f9.tar.xz puppet-61ec332144ad794fae80a16feac543afc014a5f9.zip | |
Removing the Transaction::Change#transaction accessor.
As with Events, this was never used (beyond being
assigned), so I've gotten rid of it.
Signed-off-by: Luke Kanies <luke@madstop.com>
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/puppet/transaction.rb | 1 | ||||
| -rw-r--r-- | lib/puppet/transaction/change.rb | 15 |
2 files changed, 2 insertions, 14 deletions
diff --git a/lib/puppet/transaction.rb b/lib/puppet/transaction.rb index 695d0434c..f3defb7a2 100644 --- a/lib/puppet/transaction.rb +++ b/lib/puppet/transaction.rb @@ -111,7 +111,6 @@ class Transaction changes.collect { |change| @changes << change @count += 1 - change.transaction = self events = nil begin # use an array, so that changes can return more than one diff --git a/lib/puppet/transaction/change.rb b/lib/puppet/transaction/change.rb index cc7629376..396b9233e 100644 --- a/lib/puppet/transaction/change.rb +++ b/lib/puppet/transaction/change.rb @@ -4,7 +4,7 @@ require 'puppet/transaction/event' # Handle all of the work around performing an actual change, # including calling 'sync' on the properties and producing events. class Puppet::Transaction::Change - attr_accessor :is, :should, :type, :path, :property, :transaction, :changed, :proxy + attr_accessor :is, :should, :type, :path, :property, :changed, :proxy # The log file generated when this object was changed. attr_reader :report @@ -14,11 +14,6 @@ class Puppet::Transaction::Change @property.should = @is @is = @property.retrieve - unless transaction - raise Puppet::Error, - "PropertyChange '%s' tried to be executed outside of transaction" % - self - end unless @property.insync?(@is) @property.info "Backing %s" % self return self.go @@ -85,12 +80,6 @@ class Puppet::Transaction::Change end def forward - unless transaction - raise Puppet::Error, - "PropertyChange '%s' tried to be executed outside of transaction" % - self - end - return self.go end @@ -109,6 +98,6 @@ class Puppet::Transaction::Change end def to_s - return "change %s.%s(%s)" % [transaction.object_id, self.object_id, @property.change_to_s(@is, @should)] + return "change %s" % @property.change_to_s(@is, @should) end end |
