aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrédéric Buclin <LpSolit@gmail.com>2012-11-12 18:48:15 +0100
committerFrédéric Buclin <LpSolit@gmail.com>2012-11-12 18:48:15 +0100
commit72755c5193d778152fda455454a87174ef0e42f6 (patch)
tree3046e29342935df95b4e634cdf17b6138492dfc6 /chart.cgi
parentBug 808300: Requesting data for your own account using User.get should also r... (diff)
downloadbugzilla-72755c5193d778152fda455454a87174ef0e42f6.tar.gz
bugzilla-72755c5193d778152fda455454a87174ef0e42f6.tar.bz2
bugzilla-72755c5193d778152fda455454a87174ef0e42f6.zip
Bug 676844: Replace ThrowCodeError() by ThrowUserError() when the error is not triggered by the code itself
r=glob a=LpSolit
Diffstat (limited to 'chart.cgi')
-rwxr-xr-xchart.cgi6
1 files changed, 3 insertions, 3 deletions
diff --git a/chart.cgi b/chart.cgi
index 0fa073e58..7f21fd098 100755
--- a/chart.cgi
+++ b/chart.cgi
@@ -52,7 +52,7 @@ my $dbh = Bugzilla->dbh;
my $user = Bugzilla->login(LOGIN_REQUIRED);
if (!Bugzilla->feature('new_charts')) {
- ThrowCodeError('feature_disabled', { feature => 'new_charts' });
+ ThrowUserError('feature_disabled', { feature => 'new_charts' });
}
# Go back to query.cgi if we are adding a boolean chart parameter.
@@ -269,12 +269,12 @@ sub validateWidthAndHeight {
if (defined($vars->{'width'})) {
(detaint_natural($vars->{'width'}) && $vars->{'width'} > 0)
- || ThrowCodeError("invalid_dimensions");
+ || ThrowUserError("invalid_dimensions");
}
if (defined($vars->{'height'})) {
(detaint_natural($vars->{'height'}) && $vars->{'height'} > 0)
- || ThrowCodeError("invalid_dimensions");
+ || ThrowUserError("invalid_dimensions");
}
# The equivalent of 2000 square seems like a very reasonable maximum size.