X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2Fmctest.php;h=98f0eb99a5f099f401d1c6aa3a3aee52b7878462;hb=3599ce72b0fe2594bd3ae8c902555040b8a91d28;hp=14df53c590504295d8c09af9013b6760e377e5d1;hpb=587d08c5a626f8195def9f82ee83e17c85824db8;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/mctest.php b/maintenance/mctest.php index 14df53c590..98f0eb99a5 100644 --- a/maintenance/mctest.php +++ b/maintenance/mctest.php @@ -50,8 +50,8 @@ class McTest extends Maintenance { $this->fatalError( "MediaWiki isn't configured with a cache named '$cache'" ); } $servers = $wgObjectCaches[$cache]['servers']; - } elseif ( $this->hasArg() ) { - $servers = [ $this->getArg() ]; + } elseif ( $this->hasArg( 0 ) ) { + $servers = [ $this->getArg( 0 ) ]; } elseif ( $wgMainCacheType === CACHE_MEMCACHED ) { global $wgMemCachedServers; $servers = $wgMemCachedServers; @@ -102,5 +102,5 @@ class McTest extends Maintenance { } } -$maintClass = "McTest"; +$maintClass = McTest::class; require_once RUN_MAINTENANCE_IF_MAIN;