X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fapi%2FApiQueryAllDeletedRevisions.php;h=87f99dde9e6417fc83531f84b9906cfda44d00db;hb=a075f50a86be14347100f662ccd683af4f437090;hp=be1297799412be4e7a9457330f7e7f45939032bc;hpb=bbb11d244e83215e4948ead4a085d1a435f6d4c7;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/api/ApiQueryAllDeletedRevisions.php b/includes/api/ApiQueryAllDeletedRevisions.php index be12977994..87f99dde9e 100644 --- a/includes/api/ApiQueryAllDeletedRevisions.php +++ b/includes/api/ApiQueryAllDeletedRevisions.php @@ -35,7 +35,7 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase { } /** - * @param ApiPageSet $resultPageSet + * @param ApiPageSet|null $resultPageSet * @return void */ protected function run( ApiPageSet $resultPageSet = null ) { @@ -149,11 +149,7 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase { $miser_ns = null; if ( $mode == 'all' ) { - if ( $params['namespace'] !== null ) { - $namespaces = $params['namespace']; - } else { - $namespaces = MWNamespace::getValidNamespaces(); - } + $namespaces = $params['namespace'] ?? MWNamespace::getValidNamespaces(); $this->addWhereFld( 'ar_namespace', $namespaces ); // For from/to/prefix, we have to consider the potential