*/
static function newFromTitle( Title $title, $repo ) {
$data = $repo->fetchImageQuery( array(
- 'titles' => 'File:' . $title->getDBKey(),
+ 'titles' => 'File:' . $title->getDBkey(),
'iiprop' => self::getProps(),
'prop' => 'imageinfo',
'iimetadataversion' => MediaHandler::getMetadataVersion()
? count( $data['query']['redirects'] ) - 1
: -1;
if( $lastRedirect >= 0 ) {
- $newtitle = Title::newFromText( $data['query']['redirects'][$lastRedirect]['to']);
+ $newtitle = Title::newFromText( $data['query']['redirects'][$lastRedirect]['to'] );
$img = new self( $newtitle, $repo, $info, true );
if( $img ) {
$img->redirectedFrom( $title->getDBkey() );
}
$ret = array();
foreach( $metadata as $meta ) {
- $ret[ $meta['name'] ] = self::parseMetadata( $meta['value'] );
+ $ret[$meta['name']] = self::parseMetadata( $meta['value'] );
}
return $ret;
}