From: Brion Vibber Date: Tue, 8 Feb 2011 13:31:30 +0000 (+0000) Subject: Tweak for r79018: fatal errors due to something calling parser clearState when mOptio... X-Git-Tag: 1.31.0-rc.0~32114 X-Git-Url: https://git.cyclocoop.org/admin/?a=commitdiff_plain;h=7d158675b29acadcb5dc48a4367f7609ee0ea494;p=lhc%2Fweb%2Fwiklou.git Tweak for r79018: fatal errors due to something calling parser clearState when mOptions wasn't defined --- diff --git a/includes/parser/Parser.php b/includes/parser/Parser.php index b7c63bfc17..9d9ccad881 100644 --- a/includes/parser/Parser.php +++ b/includes/parser/Parser.php @@ -194,7 +194,9 @@ class Parser { $this->firstCallInit(); } $this->mOutput = new ParserOutput; - $this->mOptions->registerWatcher( array( $this->mOutput, 'recordOption' ) ); + if( $this->mOptions ) { + $this->mOptions->registerWatcher( array( $this->mOutput, 'recordOption' ) ); + } $this->mAutonumber = 0; $this->mLastSection = ''; $this->mDTopen = false;