From b3473c453808ec6505b6fe03ba30fa14ce1d7f3e Mon Sep 17 00:00:00 2001 From: Domas Mituzas Date: Sun, 13 Jan 2008 12:29:43 +0000 Subject: [PATCH] avoid calling things on $wgTitle that might be not yet initialized --- includes/OutputPage.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/OutputPage.php b/includes/OutputPage.php index 7c5af28472..a0f3fca6ca 100644 --- a/includes/OutputPage.php +++ b/includes/OutputPage.php @@ -825,9 +825,9 @@ class OutputPage { */ public function showErrorPage( $title, $msg, $params = array() ) { global $wgTitle; - - $this->mDebugtext .= 'Original title: ' . - $wgTitle->getPrefixedText() . "\n"; + if ( isset($wgTitle) ) { + $this->mDebugtext .= 'Original title: ' . $wgTitle->getPrefixedText() . "\n"; + } $this->setPageTitle( wfMsg( $title ) ); $this->setHTMLTitle( wfMsg( 'errorpagetitle' ) ); $this->setRobotpolicy( 'noindex,nofollow' ); -- 2.20.1