summaryrefslogtreecommitdiffstats
path: root/enter_bug.cgi
diff options
context:
space:
mode:
authorkiko%async.com.br <>2004-03-27 12:51:43 +0100
committerkiko%async.com.br <>2004-03-27 12:51:43 +0100
commit4df1c8fd665e5fc7c66e265b1f32b75837ae719f (patch)
treefb5150bb7dea016e53093830685d82c81ae817a6 /enter_bug.cgi
parent3374c87eb2788ca2427061df9e63167846c80b1d (diff)
downloadbugzilla-4df1c8fd665e5fc7c66e265b1f32b75837ae719f.tar.gz
bugzilla-4df1c8fd665e5fc7c66e265b1f32b75837ae719f.tar.xz
Fix for bug 234175: Remove deprecated ConnectToDatabase() and
quietly_check_login()/confirm_login() calls. Cleans up callsites (consisting of most of our CGIs), swapping (where appropriate) for calls to Bugzilla->login. Patch by Teemu Mannermaa <wicked@etlicon.fi>. r=bbaetz, kiko. a=justdave.
Diffstat (limited to 'enter_bug.cgi')
-rwxr-xr-xenter_bug.cgi11
1 files changed, 3 insertions, 8 deletions
diff --git a/enter_bug.cgi b/enter_bug.cgi
index eca672a45..1dd02c90c 100755
--- a/enter_bug.cgi
+++ b/enter_bug.cgi
@@ -57,20 +57,15 @@ use vars qw(
$proddesc
);
-# We have to connect to the database, even though we don't use it in this code,
-# because we might occasionally rebuild the version cache, which causes tokens
-# to get deleted from the database, which needs a database connection.
-ConnectToDatabase();
-
# If we're using bug groups to restrict bug entry, we need to know who the
# user is right from the start.
-confirm_login() if AnyEntryGroups();
+Bugzilla->login(LOGIN_REQUIRED) if AnyEntryGroups();
my $cgi = Bugzilla->cgi;
if (!defined $::FORM{'product'}) {
GetVersionTable();
- quietly_check_login();
+ Bugzilla->login();
my %products;
@@ -225,7 +220,7 @@ sub pickos {
# End of subroutines
##############################################################################
-confirm_login() if (!(AnyEntryGroups()));
+Bugzilla->login(LOGIN_REQUIRED) if (!(AnyEntryGroups()));
# We need to check and make sure
# that the user has permission to enter a bug against this product.