summaryrefslogtreecommitdiffstats
path: root/extensions/TrackingFlags/lib/Flag.pm
diff options
context:
space:
mode:
Diffstat (limited to 'extensions/TrackingFlags/lib/Flag.pm')
-rw-r--r--extensions/TrackingFlags/lib/Flag.pm10
1 files changed, 10 insertions, 0 deletions
diff --git a/extensions/TrackingFlags/lib/Flag.pm b/extensions/TrackingFlags/lib/Flag.pm
index cfda0bad5..7b6effa98 100644
--- a/extensions/TrackingFlags/lib/Flag.pm
+++ b/extensions/TrackingFlags/lib/Flag.pm
@@ -87,6 +87,16 @@ sub new {
return $class->SUPER::new($param);
}
+sub new_from_hash {
+ my $class = shift;
+ my $cache = Bugzilla->request_cache->{'tracking_flags'} //= {};
+ my $flag = $class->SUPER::new_from_hash(@_);
+ if ($flag) {
+ push @Bugzilla::Extension::TrackingFlags::FLAG_CACHE, $flag;
+ }
+ return $flag;
+}
+
sub create {
my $class = shift;
my $params = shift;