From: Chad Horohoe Date: Fri, 7 Nov 2014 18:36:29 +0000 (-0800) Subject: Improved/additional logging for $wgTitle abuses X-Git-Tag: 1.31.0-rc.0~13334^2 X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_ecrire%28%22articles_versions%22%2C%22id_article=%24id_article%22%29%20.%20%22?a=commitdiff_plain;h=95e6efc4d490911b4206503d9d26f832788cf97b;p=lhc%2Fweb%2Fwiklou.git Improved/additional logging for $wgTitle abuses Change-Id: I6599aa8abe30c1888ab5df023a0d4bf346315400 --- diff --git a/includes/cache/MessageCache.php b/includes/cache/MessageCache.php index 99dafa60cc..7cd1377ee3 100644 --- a/includes/cache/MessageCache.php +++ b/includes/cache/MessageCache.php @@ -1059,6 +1059,7 @@ class MessageCache { wfProfileIn( __METHOD__ ); if ( !$title || !$title instanceof Title ) { global $wgTitle; + wfDebugLog( 'GlobalTitleFail', __METHOD__ . ' called by ' . wfGetAllCallers() . ' with no title set.' ); $title = $wgTitle; } // Sometimes $wgTitle isn't set either... diff --git a/includes/context/RequestContext.php b/includes/context/RequestContext.php index 059f18c133..d620be9c87 100644 --- a/includes/context/RequestContext.php +++ b/includes/context/RequestContext.php @@ -140,7 +140,7 @@ class RequestContext implements IContextSource { if ( $this->title === null ) { global $wgTitle; # fallback to $wg till we can improve this $this->title = $wgTitle; - wfDebugLog( 'GlobalTitleFail', __METHOD__ . ' called by ' . wfGetCaller() . ' with no title set.' ); + wfDebugLog( 'GlobalTitleFail', __METHOD__ . ' called by ' . wfGetAllCallers() . ' with no title set.' ); } return $this->title;