diff options
author | lpsolit%gmail.com <> | 2009-01-25 13:42:51 +0100 |
---|---|---|
committer | lpsolit%gmail.com <> | 2009-01-25 13:42:51 +0100 |
commit | b2b03103bba9927d5f1b123e0ad7ae1e04149dc8 (patch) | |
tree | e4845cde1af1ada8ca0d43e8c42be6d589e9a936 /show_bug.cgi | |
parent | 812ad9b3515aff6d9d870c2a11845b7416e40288 (diff) | |
download | bugzilla-b2b03103bba9927d5f1b123e0ad7ae1e04149dc8.tar.gz bugzilla-b2b03103bba9927d5f1b123e0ad7ae1e04149dc8.tar.xz |
Bug 471880: More scripts should use the shadow DB instead of the master DB - Patch by Frédéric Buclin <LpSolit@gmail.com> r=mkanat a=LpSolit
Diffstat (limited to 'show_bug.cgi')
-rwxr-xr-x | show_bug.cgi | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/show_bug.cgi b/show_bug.cgi index 62575c5ce..0578733be 100755 --- a/show_bug.cgi +++ b/show_bug.cgi @@ -55,6 +55,11 @@ my $format = $template->get_format("bug/show", scalar $cgi->param('format'), my @bugs = (); my %marks; +# If the user isn't logged in, we use data from the shadow DB. If he plans +# to edit the bug(s), he will have to log in first, meaning that the data +# will be reloaded anyway, from the main DB. +Bugzilla->switch_to_shadow_db unless $user->id; + if ($single) { my $id = $cgi->param('id'); push @bugs, Bugzilla::Bug->check($id); |