[Bps-public-commit] r20165 - RT-BugTracker-Public/html/Elements

ruz at bestpractical.com ruz at bestpractical.com
Tue Dec 1 00:12:34 EST 2009


Author: ruz
Date: Tue Dec  1 00:11:49 2009
New Revision: 20165

Modified:
   RT-BugTracker-Public/html/Elements/PersonalQuickbar

Log:
* looks like CurrentUser in the %session can be undef these days

Modified: RT-BugTracker-Public/html/Elements/PersonalQuickbar
==============================================================================
--- RT-BugTracker-Public/html/Elements/PersonalQuickbar	(original)
+++ RT-BugTracker-Public/html/Elements/PersonalQuickbar	Tue Dec  1 00:11:49 2009
@@ -21,13 +21,13 @@
 $Prefs => '/Prefs/Other.html'
 </%ARGS>
 <%INIT>
-my $logged_in = $session{'CurrentUser'}->Name;
+my $logged_in = $session{'CurrentUser'} && $session{'CurrentUser'}->Name;
 my ($can_modify_self, $public_user, $return_url) = (0, 0, '');
 if ( $logged_in ) {
     $can_modify_self = $session{'CurrentUser'}->HasRight(
         Right => 'ModifySelf', Object => $RT::System,
     ) if $Prefs;
-    $public_user = $logged_in eq $RT::WebPublicUser;
+    $public_user = $logged_in eq RT->Config->Get('WebPublicUser');
 }
 
 if ( $public_user ) {



More information about the Bps-public-commit mailing list