aboutsummaryrefslogtreecommitdiffstats
path: root/editkeywords.cgi
diff options
context:
space:
mode:
authorFrédéric Buclin <LpSolit@gmail.com>2012-11-12 18:46:48 +0100
committerFrédéric Buclin <LpSolit@gmail.com>2012-11-12 18:46:48 +0100
commit2a6f7d4663dfc5cb00c1bb8b8d8139869a22d461 (patch)
tree0267c67f18e8099384bc7ae15f58a4459ed71f63 /editkeywords.cgi
parent34a9d58c4ab24390a21595edc08442651cfbe312 (diff)
downloadbugs-2a6f7d4663dfc5cb00c1bb8b8d8139869a22d461.tar
bugs-2a6f7d4663dfc5cb00c1bb8b8d8139869a22d461.tar.gz
bugs-2a6f7d4663dfc5cb00c1bb8b8d8139869a22d461.tar.bz2
bugs-2a6f7d4663dfc5cb00c1bb8b8d8139869a22d461.tar.xz
bugs-2a6f7d4663dfc5cb00c1bb8b8d8139869a22d461.zip
Bug 676844: Replace ThrowCodeError() by ThrowUserError() when the error is not triggered by the code itself
r=glob a=LpSolit
Diffstat (limited to 'editkeywords.cgi')
-rwxr-xr-xeditkeywords.cgi8
1 files changed, 4 insertions, 4 deletions
diff --git a/editkeywords.cgi b/editkeywords.cgi
index 7e14f80cd..5a7f6643b 100755
--- a/editkeywords.cgi
+++ b/editkeywords.cgi
@@ -97,7 +97,7 @@ if ($action eq 'new') {
if ($action eq 'edit') {
my $keyword = new Bugzilla::Keyword($key_id)
- || ThrowCodeError('invalid_keyword_id', { id => $key_id });
+ || ThrowUserError('invalid_keyword_id', { id => $key_id });
$vars->{'keyword'} = $keyword;
$vars->{'token'} = issue_session_token('edit_keyword');
@@ -116,7 +116,7 @@ if ($action eq 'edit') {
if ($action eq 'update') {
check_token_data($token, 'edit_keyword');
my $keyword = new Bugzilla::Keyword($key_id)
- || ThrowCodeError('invalid_keyword_id', { id => $key_id });
+ || ThrowUserError('invalid_keyword_id', { id => $key_id });
$keyword->set_all({
name => scalar $cgi->param('name'),
@@ -140,7 +140,7 @@ if ($action eq 'update') {
if ($action eq 'del') {
my $keyword = new Bugzilla::Keyword($key_id)
- || ThrowCodeError('invalid_keyword_id', { id => $key_id });
+ || ThrowUserError('invalid_keyword_id', { id => $key_id });
$vars->{'keyword'} = $keyword;
$vars->{'token'} = issue_session_token('delete_keyword');
@@ -154,7 +154,7 @@ if ($action eq 'del') {
if ($action eq 'delete') {
check_token_data($token, 'delete_keyword');
my $keyword = new Bugzilla::Keyword($key_id)
- || ThrowCodeError('invalid_keyword_id', { id => $key_id });
+ || ThrowUserError('invalid_keyword_id', { id => $key_id });
$keyword->remove_from_db();