Page MenuHomePhabricator

Image.php throws E_STRICT error
Closed, ResolvedPublic

Description

The declaration of newFromTitle in Image.php doesn't match the declaration in LocalFile.php which causes this E_STRICT error:

Strict standards: Declaration of Image::newFromTitle() should be compatible with that of LocalFile::newFromTitle() in /opt/cruisecontrol-bin-2.8.3/projects/wiki4di/build/wiki/includes/filerepo/Image.php on line 74


Version: 1.16.x
Severity: trivial

Details

Reference
bz25102

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 11:14 PM
bzimport set Reference to bz25102.
bzimport added a subscriber: Unknown Object (MLST).

Fixed in r72622.

Note that Image.php is ancient. I'm curious what extensions(s) you might be running that are still calling this old code.

I've also marked it for complete removal in 1.18

Hmm, I'm not sure. All my extensions use wfLocalFile. PHP just needs to autoload the file to throw the E_STRICT right?

The file shouldn't be loaded unless the class gets called :)

Yeah good point. I don't know. There are no calls to "Image::" or "new Image" in my extensions anywhere.

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