Page MenuHomePhabricator

Fatal error: Call to a member function getText() on a non-object in /var/www/mediawiki/includes/Article.php on line 311
Closed, ResolvedPublic

Description

I'm running MW trunk (r91235) and every time I open a nonexistent page, add some content and click on "Show changes" I get:

Fatal error: Call to a member function getText() on a non-object in /var/www/mediawiki/includes/Article.php on line 311

The line mentioned is this:

http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/includes/Article.php?annotate=91162&pathrev=91235#l309

@todo FIXME: Horrible, horrible! This content-loading interface just plain sucks.
We should instead work with the Revision object when we need it...

$this->mContent = $revision->getText( Revision::FOR_THIS_USER ); // Loads if user is allowed

The problem doesn't seems to happen if the page already has some text.

My LocalSettings.php contains only this (after the default contents):

#Per [[mw:Manual:How_to_debug]]
error_reporting( E_ALL | E_STRICT );
ini_set( 'display_errors', 1 );
$wgShowExceptionDetails = true;
$wgShowSQLErrors = true;

$wgDebugDumpSql = true;


Version: 1.20.x
Severity: critical

Details

Reference
bz29662

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 21 2014, 11:26 PM
bzimport set Reference to bz29662.
bzimport added a subscriber: Unknown Object (MLST).