Index: trunk/phase3/includes/ResourceLoaderModule.php |
— | — | @@ -855,6 +855,10 @@ |
856 | 856 | global $wgAllowUserCssPrefs; |
857 | 857 | if ( $wgAllowUserCssPrefs ) { |
858 | 858 | $user = User::newFromName( $context->getUser() ); |
| 859 | + if ( $user === false ) { |
| 860 | + $user = User::newFromId( 0 ); |
| 861 | + } |
| 862 | + |
859 | 863 | $rules = array(); |
860 | 864 | if ( ( $underline = $user->getOption( 'underline' ) ) < 2 ) { |
861 | 865 | $rules[] = "a { text-decoration: " . ( $underline ? 'underline' : 'none' ) . "; }"; |