[Rt-commit] rt branch, 4.2/fix-unconditionnal-lastupdated, created. rt-4.2.5-11-ga7c8d6e
Emannuel Lacour
elacour at bestpractical.com
Fri Jun 13 08:33:08 EDT 2014
The branch, 4.2/fix-unconditionnal-lastupdated has been created
at a7c8d6e66b54bed929d58979b1ba0380333385b1 (commit)
- Log -----------------------------------------------------------------
commit a7c8d6e66b54bed929d58979b1ba0380333385b1
Author: Emmanuel Lacour <elacour at easter-eggs.com>
Date: Fri Jun 13 14:32:24 2014 +0200
Update LastUpdated/LastUpdatedBy only if there is an update
diff --git a/lib/RT/Record.pm b/lib/RT/Record.pm
index c794d49..a6fae01 100644
--- a/lib/RT/Record.pm
+++ b/lib/RT/Record.pm
@@ -499,12 +499,15 @@ sub _Set {
}
my $old_val = $self->__Value($args{'Field'});
- $self->_SetLastUpdated();
my $ret = $self->SUPER::_Set(
Field => $args{'Field'},
Value => $args{'Value'},
IsSQL => $args{'IsSQL'}
);
+
+ $self->_SetLastUpdated()
+ unless ( $self->__Value( $args{'Field'} ) eq $old_val ) ;
+
my ($status, $msg) = $ret->as_array();
# @values has two values, a status code and a message.
-----------------------------------------------------------------------
More information about the rt-commit
mailing list