From 2a444f9d50535445a84367a9833bd87a07752d0a Mon Sep 17 00:00:00 2001 From: Max Kanat-Alexander Date: Thu, 1 Apr 2010 22:42:42 -0700 Subject: Bug 556695: New Hook: object_end_of_set r=mkanat, a=mkanat (module owner) --- extensions/Example/Extension.pm | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'extensions') diff --git a/extensions/Example/Extension.pm b/extensions/Example/Extension.pm index 398ddbd56..52ac66231 100644 --- a/extensions/Example/Extension.pm +++ b/extensions/Example/Extension.pm @@ -386,6 +386,17 @@ sub object_end_of_create_validators { } +sub object_end_of_set { + my ($self, $args) = @_; + + my ($object, $field) = @$args{qw(object field)}; + + # Note that this is a made-up class, for this example. + if ($object->isa('Bugzilla::ExampleObject')) { + warn "The field $field has changed to " . $object->{$field}; + } +} + sub object_end_of_set_all { my ($self, $args) = @_; -- cgit v1.2.3-24-g4f1b