summaryrefslogtreecommitdiff
path: root/includes/api/ApiQueryFileRepoInfo.php
diff options
context:
space:
mode:
authorPierre Schmitz <pierre@archlinux.de>2015-06-04 07:31:04 +0200
committerPierre Schmitz <pierre@archlinux.de>2015-06-04 07:58:39 +0200
commitf6d65e533c62f6deb21342d4901ece24497b433e (patch)
treef28adf0362d14bcd448f7b65a7aaf38650f923aa /includes/api/ApiQueryFileRepoInfo.php
parentc27b2e832fe25651ef2410fae85b41072aae7519 (diff)
Update to MediaWiki 1.25.1
Diffstat (limited to 'includes/api/ApiQueryFileRepoInfo.php')
-rw-r--r--includes/api/ApiQueryFileRepoInfo.php27
1 files changed, 6 insertions, 21 deletions
diff --git a/includes/api/ApiQueryFileRepoInfo.php b/includes/api/ApiQueryFileRepoInfo.php
index d1600efe..9ad7e27e 100644
--- a/includes/api/ApiQueryFileRepoInfo.php
+++ b/includes/api/ApiQueryFileRepoInfo.php
@@ -55,7 +55,9 @@ class ApiQueryFileRepoInfo extends ApiQueryBase {
$repos[] = array_intersect_key( $repoGroup->getLocalRepo()->getInfo(), $props );
$result = $this->getResult();
- $result->setIndexedTagName( $repos, 'repo' );
+ ApiResult::setIndexedTagName( $repos, 'repo' );
+ ApiResult::setArrayTypeRecursive( $repos, 'assoc' );
+ ApiResult::setArrayType( $repos, 'array' );
$result->addValue( array( 'query' ), 'repos', $repos );
}
@@ -89,27 +91,10 @@ class ApiQueryFileRepoInfo extends ApiQueryBase {
) ) );
}
- public function getParamDescription() {
+ protected function getExamplesMessages() {
return array(
- 'prop' => array(
- 'Which repository properties to get (there may be more available on some wikis):',
- ' apiurl - URL to the repository API - helpful for getting image info from the host.',
- ' name - The key of the repository - used in e.g. ' .
- '$wgForeignFileRepos and imageinfo return values.',
- ' displayname - The human-readable name of the repository wiki.',
- ' rooturl - Root URL for image paths.',
- ' local - Whether that repository is the local one or not.',
- ),
- );
- }
-
- public function getDescription() {
- return 'Return meta information about image repositories configured on the wiki.';
- }
-
- public function getExamples() {
- return array(
- 'api.php?action=query&meta=filerepoinfo&friprop=apiurl|name|displayname',
+ 'action=query&meta=filerepoinfo&friprop=apiurl|name|displayname'
+ => 'apihelp-query+filerepoinfo-example-simple',
);
}
}