X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2FimportImages.php;h=5a4ab394032d0aa00c36f63a91c6c1c483dfa42f;hb=c0821b20aa38c9aae5c9607874b39c7d6237df3b;hp=c653a5f06d33a89617d73bf0ef804c57a9978e65;hpb=816e6ded007382f35df38ea8f4b5a32e8e256b78;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/importImages.php b/maintenance/importImages.php index c653a5f06d..5a4ab39403 100644 --- a/maintenance/importImages.php +++ b/maintenance/importImages.php @@ -245,7 +245,8 @@ if ( $count > 0 ) { if ( isset( $options['dry'] ) ) { echo " publishing {$file} by '" . $wgUser->getName() . "', comment '$commentText'... "; } else { - $props = FSFile::getPropsFromPath( $file ); + $mwProps = new MWFileProps( MimeMagic::singleton() ); + $props = $mwProps->getPropsFromPath( $file, true ); $flags = 0; $publishOptions = []; $handler = MediaHandler::getHandler( $props['mime'] ); @@ -297,8 +298,8 @@ if ( $count > 0 ) { if ( $doProtect ) { # Protect the file - echo "\nWaiting for slaves...\n"; - // Wait for slaves. + echo "\nWaiting for replica DBs...\n"; + // Wait for replica DBs. sleep( 2.0 ); # Why this sleep? wfWaitForSlaves();