summaryrefslogtreecommitdiffstats
path: root/describecomponents.cgi
diff options
context:
space:
mode:
authorgerv%gerv.net <>2002-10-06 20:52:28 +0200
committergerv%gerv.net <>2002-10-06 20:52:28 +0200
commitb8851cdd5c15e0d21543d9fe08159b9ced8c950f (patch)
treece1c674c28c6491d3a86e3afb182963737666e2d /describecomponents.cgi
parentf50efb95e1c7462699f1179d0a62b1ee7118e67e (diff)
downloadbugzilla-b8851cdd5c15e0d21543d9fe08159b9ced8c950f.tar.gz
bugzilla-b8851cdd5c15e0d21543d9fe08159b9ced8c950f.tar.xz
Bug 163114 - Templatise all calls to DisplayError. Patch D (the last one). Patch by gerv; r=burnus.
Diffstat (limited to 'describecomponents.cgi')
-rwxr-xr-xdescribecomponents.cgi7
1 files changed, 2 insertions, 5 deletions
diff --git a/describecomponents.cgi b/describecomponents.cgi
index 7a24b692c..b4953ddc6 100755
--- a/describecomponents.cgi
+++ b/describecomponents.cgi
@@ -57,9 +57,7 @@ if (!defined $::FORM{'product'}) {
my $prodsize = scalar(keys %products);
if ($prodsize == 0) {
- DisplayError("Either no products have been defined ".
- "or you have not been given access to any.\n");
- exit;
+ ThrowUserError("no_products");
}
elsif ($prodsize > 1) {
$::vars->{'proddesc'} = \%products;
@@ -93,8 +91,7 @@ if (!$product_id) {
if (Param("usebuggroups") && GroupExists($product)) {
confirm_login() unless $::userid;
UserInGroup($product)
- || DisplayError("You are not authorized to access that product.")
- && exit;
+ || ThrowUserError("product_access_denied");
}
######################################################################