From 6368cfad3ea49b6220598d2e362defbc820b9c36 Mon Sep 17 00:00:00 2001 From: "bbaetz%student.usyd.edu.au" <> Date: Wed, 15 Jan 2003 04:00:05 +0000 Subject: Bug 163290 - move DB handling code into a module r=justdave, myk, joel, preed a=justdave --- reports.cgi | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'reports.cgi') diff --git a/reports.cgi b/reports.cgi index e18d3ee37..230fe32db 100755 --- a/reports.cgi +++ b/reports.cgi @@ -51,13 +51,17 @@ $@ && ThrowCodeError("chart_lines_not_installed"); my $dir = "data/mining"; my $graph_dir = "graphs"; +use Bugzilla; + # If we're using bug groups for products, we should apply those restrictions # to viewing reports, as well. Time to check the login in that case. -ConnectToDatabase(1); +ConnectToDatabase(); quietly_check_login(); GetVersionTable(); +Bugzilla->instance->switch_to_shadow_db(); + # We only want those products that the user has permissions for. my @myproducts; push( @myproducts, "-All-"); -- cgit v1.2.3-24-g4f1b