X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2FMaintenance.php;h=6e545a69e4ade8ed6d997bf83120cba05120350e;hb=a44ae41d5806992c7b5524b8098022856f03f016;hp=b3e958f745ce3c659672575ba7821642a5857cbd;hpb=962eec295d7d35e2e169873c0cdf88941d7ef62c;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/Maintenance.php b/maintenance/Maintenance.php index b3e958f745..6e545a69e4 100644 --- a/maintenance/Maintenance.php +++ b/maintenance/Maintenance.php @@ -336,6 +336,10 @@ abstract class Maintenance { * @return bool */ protected function hasArg( $argId = 0 ) { + if ( func_num_args() === 0 ) { + wfDeprecated( __METHOD__ . ' without an $argId', '1.33' ); + } + return isset( $this->mArgs[$argId] ); } @@ -346,6 +350,10 @@ abstract class Maintenance { * @return mixed */ protected function getArg( $argId = 0, $default = null ) { + if ( func_num_args() === 0 ) { + wfDeprecated( __METHOD__ . ' without an $argId', '1.33' ); + } + return $this->hasArg( $argId ) ? $this->mArgs[$argId] : $default; }