r81127 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r81126‎ | r81127 | r81128 >
Date:12:37, 28 January 2011
Author:jeroendedauw
Status:deferred
Tags:
Comment:
Took care of bug 27009
Modified paths:
  • /trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_Ask.php (modified) (history)
  • /trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_Concept.php (modified) (history)
  • /trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_Declare.php (modified) (history)
  • /trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_Info.php (modified) (history)
  • /trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_SetRecurringEvent.php (modified) (history)
  • /trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_Show.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_Concept.php
@@ -73,7 +73,7 @@
7474 '<pre>' . str_replace( '[', '&#x005B;', $concept_text ) . "</pre>\n</div>";
7575
7676 // Starting from MW 1.16, there is a more suited method available: Title::isSpecialPage
77 - if ( $wgTitle->getNamespace() == NS_SPECIAL ) {
 77+ if ( !is_null( $wgTitle ) && $wgTitle->getNamespace() == NS_SPECIAL ) {
7878 global $wgOut;
7979 SMWOutputs::commitToOutputPage( $wgOut );
8080 }
Index: trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_Info.php
@@ -31,7 +31,7 @@
3232
3333 // Starting from MW 1.16, there is a more suited method available: Title::isSpecialPage
3434 global $wgTitle;
35 - if ( $wgTitle->getNamespace() == NS_SPECIAL ) {
 35+ if ( !is_null( $wgTitle ) && $wgTitle->getNamespace() == NS_SPECIAL ) {
3636 global $wgOut;
3737 SMWOutputs::commitToOutputPage( $wgOut );
3838 }
Index: trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_Ask.php
@@ -38,7 +38,7 @@
3939 }
4040
4141 // Starting from MW 1.16, there is a more suited method available: Title::isSpecialPage
42 - if ( $wgTitle->getNamespace() == NS_SPECIAL ) {
 42+ if ( !is_null( $wgTitle ) && $wgTitle->getNamespace() == NS_SPECIAL ) {
4343 global $wgOut;
4444 SMWOutputs::commitToOutputPage( $wgOut );
4545 }
Index: trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_SetRecurringEvent.php
@@ -42,7 +42,7 @@
4343
4444 // Starting from MW 1.16, there is a more suited method available: Title::isSpecialPage
4545 global $wgTitle;
46 - if ( $wgTitle->getNamespace() == NS_SPECIAL ) {
 46+ if ( !is_null( $wgTitle ) && $wgTitle->getNamespace() == NS_SPECIAL ) {
4747 global $wgOut;
4848 SMWOutputs::commitToOutputPage( $wgOut );
4949 }
Index: trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_Declare.php
@@ -76,7 +76,7 @@
7777
7878 // Starting from MW 1.16, there is a more suited method available: Title::isSpecialPage
7979 global $wgTitle;
80 - if ( $wgTitle->getNamespace() == NS_SPECIAL ) {
 80+ if ( !is_null( $wgTitle ) && $wgTitle->getNamespace() == NS_SPECIAL ) {
8181 global $wgOut;
8282 SMWOutputs::commitToOutputPage( $wgOut );
8383 }
Index: trunk/extensions/SemanticMediaWiki/includes/parserhooks/SMW_Show.php
@@ -38,7 +38,7 @@
3939 }
4040
4141 // Starting from MW 1.16, there is a more suited method available: Title::isSpecialPage
42 - if ( $wgTitle->getNamespace() == NS_SPECIAL ) {
 42+ if ( !is_null( $wgTitle ) && $wgTitle->getNamespace() == NS_SPECIAL ) {
4343 global $wgOut;
4444 SMWOutputs::commitToOutputPage( $wgOut );
4545 }

Status & tagging log