summaryrefslogtreecommitdiffstats
path: root/Bugzilla/Util.pm
diff options
context:
space:
mode:
authorMax Kanat-Alexander <mkanat@bugzilla.org>2011-01-04 03:09:42 +0100
committerMax Kanat-Alexander <mkanat@bugzilla.org>2011-01-04 03:09:42 +0100
commitb6d1cc32f75d47437e382caccfccc5b2d98af765 (patch)
tree2ceff059de13f820287c0a84f248d55ef5630aff /Bugzilla/Util.pm
parenta1fa8d5f9f196d8611c64c1625e8269c9df52214 (diff)
downloadbugzilla-b6d1cc32f75d47437e382caccfccc5b2d98af765.tar.gz
bugzilla-b6d1cc32f75d47437e382caccfccc5b2d98af765.tar.xz
Bug 595410: Make it faster to display a bug that has a lot of dependencies.
r=LpSolit, a=LpSolit
Diffstat (limited to 'Bugzilla/Util.pm')
-rw-r--r--Bugzilla/Util.pm9
1 files changed, 9 insertions, 0 deletions
diff --git a/Bugzilla/Util.pm b/Bugzilla/Util.pm
index 6f29a1201..457eb7d02 100644
--- a/Bugzilla/Util.pm
+++ b/Bugzilla/Util.pm
@@ -639,6 +639,15 @@ sub template_var {
return $vars{$name};
}
+sub display_value {
+ my ($field, $value) = @_;
+ my $value_descs = template_var('value_descs');
+ if (defined $value_descs->{$field}->{$value}) {
+ return $value_descs->{$field}->{$value};
+ }
+ return $value;
+}
+
sub disable_utf8 {
if (Bugzilla->params->{'utf8'}) {
binmode STDOUT, ':bytes'; # Turn off UTF8 encoding.