Page MenuHomePhabricator

Call to a member function isError() on a non-object in includes/filerepo/file/File.php on line 907
Closed, ResolvedPublic

Description

Observed at translatewiki.net: PHP Fatal error: Call to a member function isError() on a non-object in /www/translatewiki.net/w/includes/filerepo/file/File.php on line 907

Code snippet:

$thumb = $this->transform( $params );
if ( is_null( $thumb ) || $thumb->isError() ) {
    return '';
}

Happens when $thumb is false, which means that $thumb->isError() is called on a non-object.


Version: unspecified
Severity: normal

Details

Reference
bz58436

Event Timeline

bzimport raised the priority of this task from to High.Nov 22 2014, 2:19 AM
bzimport set Reference to bz58436.
bzimport added a subscriber: Unknown Object (MLST).

Change 101179 had a related patch set uploaded by Brian Wolff:
Fix error handling in File::createThumb.

https://gerrit.wikimedia.org/r/101179

Change 101179 merged by jenkins-bot:
Fix error handling in File::createThumb.

https://gerrit.wikimedia.org/r/101179

Gilles raised the priority of this task from High to Unbreak Now!.Dec 4 2014, 10:21 AM
Gilles moved this task from Untriaged to Done on the Multimedia board.
Gilles lowered the priority of this task from Unbreak Now! to High.Dec 4 2014, 11:23 AM