Merge "Replace Linker::link() usage with LinkRenderer"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Thu, 8 Dec 2016 18:34:27 +0000 (18:34 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Thu, 8 Dec 2016 18:34:27 +0000 (18:34 +0000)
288 files changed:
.gitignore
RELEASE-NOTES-1.29
autoload.php
composer.json
docs/hooks.txt
includes/AuthPlugin.php
includes/FileDeleteForm.php
includes/RevisionList.php
includes/Setup.php
includes/WatchedItemQueryService.php
includes/actions/HistoryAction.php
includes/api/ApiAMCreateAccount.php
includes/api/ApiAuthManagerHelper.php
includes/api/ApiBase.php
includes/api/ApiBlock.php
includes/api/ApiCSPReport.php
includes/api/ApiChangeAuthenticationData.php
includes/api/ApiCheckToken.php
includes/api/ApiClientLogin.php
includes/api/ApiComparePages.php
includes/api/ApiContinuationManager.php
includes/api/ApiDelete.php
includes/api/ApiDisabled.php
includes/api/ApiEditPage.php
includes/api/ApiEmailUser.php
includes/api/ApiErrorFormatter.php
includes/api/ApiExpandTemplates.php
includes/api/ApiFeedContributions.php
includes/api/ApiFeedRecentChanges.php
includes/api/ApiFeedWatchlist.php
includes/api/ApiFileRevert.php
includes/api/ApiFormatJson.php
includes/api/ApiFormatPhp.php
includes/api/ApiFormatRaw.php
includes/api/ApiFormatXml.php
includes/api/ApiImageRotate.php
includes/api/ApiImport.php
includes/api/ApiLinkAccount.php
includes/api/ApiLogin.php
includes/api/ApiLogout.php
includes/api/ApiMain.php
includes/api/ApiManageTags.php
includes/api/ApiMergeHistory.php
includes/api/ApiMessage.php
includes/api/ApiMove.php
includes/api/ApiOpenSearch.php
includes/api/ApiOptions.php
includes/api/ApiPageSet.php
includes/api/ApiParamInfo.php
includes/api/ApiParse.php
includes/api/ApiPatrol.php
includes/api/ApiProtect.php
includes/api/ApiPurge.php
includes/api/ApiQuery.php
includes/api/ApiQueryAllDeletedRevisions.php
includes/api/ApiQueryAllImages.php
includes/api/ApiQueryAllLinks.php
includes/api/ApiQueryAllMessages.php
includes/api/ApiQueryAllPages.php
includes/api/ApiQueryAllUsers.php
includes/api/ApiQueryBacklinks.php
includes/api/ApiQueryBacklinksprop.php
includes/api/ApiQueryBase.php
includes/api/ApiQueryBlocks.php
includes/api/ApiQueryCategories.php
includes/api/ApiQueryCategoryMembers.php
includes/api/ApiQueryDeletedRevisions.php
includes/api/ApiQueryDeletedrevs.php
includes/api/ApiQueryDisabled.php
includes/api/ApiQueryFilearchive.php
includes/api/ApiQueryIWBacklinks.php
includes/api/ApiQueryIWLinks.php
includes/api/ApiQueryImageInfo.php
includes/api/ApiQueryImages.php
includes/api/ApiQueryInfo.php
includes/api/ApiQueryLangBacklinks.php
includes/api/ApiQueryLangLinks.php
includes/api/ApiQueryLinks.php
includes/api/ApiQueryLogEvents.php
includes/api/ApiQueryMyStashedFiles.php
includes/api/ApiQueryQueryPage.php
includes/api/ApiQueryRecentChanges.php
includes/api/ApiQueryRevisions.php
includes/api/ApiQueryRevisionsBase.php
includes/api/ApiQuerySearch.php
includes/api/ApiQuerySiteinfo.php
includes/api/ApiQueryStashImageInfo.php
includes/api/ApiQueryTokens.php
includes/api/ApiQueryUserContributions.php
includes/api/ApiQueryUserInfo.php
includes/api/ApiQueryUsers.php
includes/api/ApiQueryWatchlist.php
includes/api/ApiQueryWatchlistRaw.php
includes/api/ApiRemoveAuthenticationData.php
includes/api/ApiResetPassword.php
includes/api/ApiResult.php
includes/api/ApiRevisionDelete.php
includes/api/ApiRollback.php
includes/api/ApiSetNotificationTimestamp.php
includes/api/ApiStashEdit.php
includes/api/ApiTag.php
includes/api/ApiTokens.php
includes/api/ApiUnblock.php
includes/api/ApiUndelete.php
includes/api/ApiUpload.php
includes/api/ApiUsageException.php [new file with mode: 0644]
includes/api/ApiWatch.php
includes/api/i18n/ar.json
includes/api/i18n/de.json
includes/api/i18n/en.json
includes/api/i18n/es.json
includes/api/i18n/fr.json
includes/api/i18n/gl.json
includes/api/i18n/he.json
includes/api/i18n/hu.json
includes/api/i18n/id.json
includes/api/i18n/ja.json
includes/api/i18n/ko.json
includes/api/i18n/lb.json
includes/api/i18n/mk.json
includes/api/i18n/nb.json
includes/api/i18n/pl.json
includes/api/i18n/pt.json
includes/api/i18n/qqq.json
includes/api/i18n/uk.json
includes/api/i18n/zh-hans.json
includes/htmlform/fields/HTMLTagFilter.php
includes/installer/i18n/bn.json
includes/installer/i18n/fr.json
includes/installer/i18n/ko.json
includes/installer/i18n/qqq.json
includes/installer/i18n/zh-hans.json
includes/installer/i18n/zh-hant.json
includes/libs/MapCacheLRU.php
includes/libs/Xhprof.php
includes/libs/objectcache/APCUBagOStuff.php
includes/libs/rdbms/database/DatabaseSqlite.php
includes/libs/rdbms/loadbalancer/LoadBalancer.php
includes/logging/LogEventsList.php
includes/objectcache/SqlBagOStuff.php
includes/page/WikiFilePage.php
includes/page/WikiPage.php
includes/profiler/ProfilerXhprof.php
includes/registration/ExtensionJsonValidationError.php [new file with mode: 0644]
includes/registration/ExtensionJsonValidator.php [new file with mode: 0644]
includes/registration/ExtensionProcessor.php
includes/registration/ExtensionRegistry.php
includes/revisiondelete/RevDelArchiveItem.php
includes/revisiondelete/RevDelArchivedFileItem.php
includes/revisiondelete/RevDelFileItem.php
includes/revisiondelete/RevDelLogItem.php
includes/revisiondelete/RevDelRevisionItem.php
includes/skins/SkinTemplate.php
includes/specialpage/ChangesListSpecialPage.php
includes/specials/SpecialApiHelp.php
includes/specials/SpecialContributions.php
includes/specials/SpecialDeletedContributions.php
includes/specials/SpecialEmailuser.php
includes/specials/SpecialRecentchanges.php
includes/specials/SpecialUnblock.php
includes/specials/SpecialUserrights.php
includes/specials/SpecialWatchlist.php
includes/specials/pagers/AllMessagesTablePager.php
includes/specials/pagers/BlockListPager.php
includes/specials/pagers/ContribsPager.php
includes/specials/pagers/DeletedContribsPager.php
includes/specials/pagers/ImageListPager.php
languages/data/ZhConversion.php
languages/i18n/ar.json
languages/i18n/azb.json
languages/i18n/ba.json
languages/i18n/be-tarask.json
languages/i18n/bho.json
languages/i18n/bn.json
languages/i18n/bs.json
languages/i18n/ca.json
languages/i18n/cs.json
languages/i18n/de.json
languages/i18n/diq.json
languages/i18n/en.json
languages/i18n/et.json
languages/i18n/fa.json
languages/i18n/fi.json
languages/i18n/fr.json
languages/i18n/gl.json
languages/i18n/he.json
languages/i18n/hr.json
languages/i18n/ia.json
languages/i18n/id.json
languages/i18n/it.json
languages/i18n/ja.json
languages/i18n/jv.json
languages/i18n/kk-cyrl.json
languages/i18n/ko.json
languages/i18n/lb.json
languages/i18n/lv.json
languages/i18n/mk.json
languages/i18n/nah.json
languages/i18n/nb.json
languages/i18n/oc.json
languages/i18n/pl.json
languages/i18n/pt-br.json
languages/i18n/pt.json
languages/i18n/qqq.json
languages/i18n/ro.json
languages/i18n/roa-tara.json
languages/i18n/ru.json
languages/i18n/sah.json
languages/i18n/sd.json
languages/i18n/sl.json
languages/i18n/sq.json
languages/i18n/sv.json
languages/i18n/udm.json
languages/i18n/zh-hans.json
languages/i18n/zh-hant.json
maintenance/backup.inc
maintenance/language/zhtable/toSimp.manual
maintenance/language/zhtable/toTrad.manual
maintenance/language/zhtable/tradphrases.manual
maintenance/language/zhtable/tradphrases_exclude.manual
maintenance/validateRegistrationFile.php
resources/lib/oojs-ui/oojs-ui-apex.js
resources/lib/oojs-ui/oojs-ui-core-apex.css
resources/lib/oojs-ui/oojs-ui-core-mediawiki.css
resources/lib/oojs-ui/oojs-ui-core.js
resources/lib/oojs-ui/oojs-ui-mediawiki.js
resources/lib/oojs-ui/oojs-ui-toolbars-apex.css
resources/lib/oojs-ui/oojs-ui-toolbars-mediawiki.css
resources/lib/oojs-ui/oojs-ui-toolbars.js
resources/lib/oojs-ui/oojs-ui-widgets-apex.css
resources/lib/oojs-ui/oojs-ui-widgets-mediawiki.css
resources/lib/oojs-ui/oojs-ui-widgets.js
resources/lib/oojs-ui/oojs-ui-windows-apex.css
resources/lib/oojs-ui/oojs-ui-windows-mediawiki.css
resources/lib/oojs-ui/oojs-ui-windows.js
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin-invert.png
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin-progressive.png
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin-progressive.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin.png
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr-invert.png
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr-progressive.png
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr-progressive.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr.png
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl-invert.png
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl-progressive.png
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl-progressive.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl.png
resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl.svg
resources/src/mediawiki/page/rollback.js
tests/phan/bin/phan [new file with mode: 0755]
tests/phan/config.php [new file with mode: 0644]
tests/phan/issues/.gitkeep [new file with mode: 0644]
tests/phan/stubs/README [new file with mode: 0644]
tests/phan/stubs/hhvm.php [new file with mode: 0644]
tests/phan/stubs/mail.php [new file with mode: 0644]
tests/phan/stubs/wikidiff.php [new file with mode: 0644]
tests/phpunit/ResourceLoaderTestCase.php
tests/phpunit/includes/WatchedItemQueryServiceUnitTest.php
tests/phpunit/includes/api/ApiBaseTest.php
tests/phpunit/includes/api/ApiBlockTest.php
tests/phpunit/includes/api/ApiContinuationManagerTest.php
tests/phpunit/includes/api/ApiEditPageTest.php
tests/phpunit/includes/api/ApiErrorFormatterTest.php
tests/phpunit/includes/api/ApiMainTest.php
tests/phpunit/includes/api/ApiMessageTest.php
tests/phpunit/includes/api/ApiOptionsTest.php
tests/phpunit/includes/api/ApiParseTest.php
tests/phpunit/includes/api/ApiQueryWatchlistIntegrationTest.php
tests/phpunit/includes/api/ApiQueryWatchlistRawIntegrationTest.php
tests/phpunit/includes/api/ApiTestCase.php
tests/phpunit/includes/api/ApiUnblockTest.php
tests/phpunit/includes/api/ApiUploadTest.php
tests/phpunit/includes/api/ApiWatchTest.php
tests/phpunit/includes/api/MockApi.php
tests/phpunit/includes/api/MockApiQueryBase.php
tests/phpunit/includes/api/format/ApiFormatPhpTest.php
tests/phpunit/includes/api/format/ApiFormatXmlTest.php
tests/phpunit/includes/api/query/ApiQueryTest.php
tests/phpunit/includes/resourceloader/ResourceLoaderFileModuleTest.php
tests/phpunit/includes/resourceloader/ResourceLoaderImageTest.php
tests/phpunit/includes/specials/SpecialRecentchangesTest.php
tests/phpunit/includes/upload/UploadFromUrlTest.php
tests/phpunit/structure/ExtensionJsonValidationTest.php

index 01a11bf..b2c4d45 100644 (file)
@@ -71,3 +71,4 @@ Thumbs.db
 /tags
 /.htaccess
 /.htpasswd
+/tests/phan/issues
index 1c90e88..986ecd8 100644 (file)
@@ -14,6 +14,14 @@ production.
   will still be blocked.
 * The resetpassword right and associated password reset capture feature has
   been removed.
+* The $error parameter to the EmailUser hook should be set to a Status object
+  or boolean false. This should be compatible with at least MediaWiki 1.23 if
+  not earlier. Returning a raw HTML string is now deprecated.
+* The $message parameter to the ApiCheckCanExecute hook should be set to an
+  ApiMessage. This is compatible with MediaWiki 1.27 and later. Returning a
+  code for ApiBase::parseMsg() will no longer work.
+* ApiBase::$messageMap is no longer public. Code attempting to access it will
+  result in a PHP fatal error.
 
 === New features in 1.29 ===
 * (T5233) A cookie can now be set when a user is autoblocked, to track that user if
@@ -37,8 +45,47 @@ production.
   body instead.
 * The capture option for action=resetpassword has been removed
 * action=clearhasmsg now requires a POST.
+* (T47843) API errors and warnings may be requested in non-English languages
+  using the new 'errorformat', 'errorlang', and 'errorsuselocal' parameters.
+* API error codes may have changed. Most notably, errors from modules using
+  parameter prefixes (e.g. all query submodules) will no longer be prefixed.
+* action=emailuser may return a "Warnings" status, and now returns 'warnings' and
+  'errors' subelements (as applicable) instead of 'message'.
+* action=imagerotate returns an 'errors' subelement rather than 'errormessage'.
+* action=move now reports errors when moving the talk page as an array under
+  key 'talkmove-errors', rather than using 'talkmove-error-code' and
+  'talkmove-error-info'. The format for subpage move errors has also changed.
+* action=revisiondelete no longer includes a "rendered" property on warnings
+  and errors for each item. Use errorformat=wikitext if you're wanting parsed
+  output.
+* action=rollback no longer returns a "messageHtml" property on errors. Use
+  errorformat=html if you're wanting HTML formatting of messages.
+* action=upload now reports optional stash failures as an array under key
+  'stasherrors' rather than a 'stashfailed' text string.
+* action=watch reports 'errors' and 'warnings' instead of a single 'error'.
 
 === Action API internal changes in 1.29 ===
+* New methods were added to ApiBase to handle errors and warnings using i18n
+  keys. Methods for using hard-coded English messages were deprecated:
+  * ApiBase::dieUsage() was deprecated
+  * ApiBase::dieUsageMsg() was deprecated
+  * ApiBase::dieUsageMsgOrDebug() was deprecated
+  * ApiBase::getErrorFromStatus() was deprecated
+  * ApiBase::parseMsg() was deprecated
+  * ApiBase::setWarning() was deprecated
+* ApiBase::$messageMap is no longer public. Code attempting to access it will
+  result in a PHP fatal error.
+* The $message parameter to the ApiCheckCanExecute hook should be set to an
+  ApiMessage. This is compatible with MediaWiki 1.27 and later. Returning a
+  code for ApiBase::parseMsg() will no longer work.
+* UsageException is deprecated in favor of ApiUsageException. For the time
+  being ApiUsageException is a subclass of UsageException to allow things that
+  catch only UsageException to still function properly.
+* If, for some strange reason, code was using an ApiErrorFormatter instead of
+  ApiErrorFormatter_BackCompat, note that the result format has changed and
+  various methods now take a module path rather than a module name.
+* ApiMessageTrait::getApiCode() now strips 'apierror-' and 'apiwarn-' prefixes
+  from the message key, and maps some message keys for backwards compatibility.
 
 === Languages updated in 1.29 ===
 
index f74128a..e079686 100644 (file)
@@ -145,6 +145,7 @@ $wgAutoloadLocalClasses = [
        'ApiUnblock' => __DIR__ . '/includes/api/ApiUnblock.php',
        'ApiUndelete' => __DIR__ . '/includes/api/ApiUndelete.php',
        'ApiUpload' => __DIR__ . '/includes/api/ApiUpload.php',
+       'ApiUsageException' => __DIR__ . '/includes/api/ApiUsageException.php',
        'ApiUserrights' => __DIR__ . '/includes/api/ApiUserrights.php',
        'ApiWatch' => __DIR__ . '/includes/api/ApiWatch.php',
        'ArchivedFile' => __DIR__ . '/includes/filerepo/file/ArchivedFile.php',
@@ -428,6 +429,8 @@ $wgAutoloadLocalClasses = [
        'ExplodeIterator' => __DIR__ . '/includes/libs/ExplodeIterator.php',
        'ExportProgressFilter' => __DIR__ . '/maintenance/backup.inc',
        'ExportSites' => __DIR__ . '/maintenance/exportSites.php',
+       'ExtensionJsonValidationError' => __DIR__ . '/includes/registration/ExtensionJsonValidationError.php',
+       'ExtensionJsonValidator' => __DIR__ . '/includes/registration/ExtensionJsonValidator.php',
        'ExtensionLanguages' => __DIR__ . '/maintenance/language/languages.inc',
        'ExtensionProcessor' => __DIR__ . '/includes/registration/ExtensionProcessor.php',
        'ExtensionRegistry' => __DIR__ . '/includes/registration/ExtensionRegistry.php',
@@ -1501,7 +1504,7 @@ $wgAutoloadLocalClasses = [
        'UploadStashWrongOwnerException' => __DIR__ . '/includes/upload/UploadStash.php',
        'UploadStashZeroLengthFileException' => __DIR__ . '/includes/upload/UploadStash.php',
        'UppercaseCollation' => __DIR__ . '/includes/collation/UppercaseCollation.php',
-       'UsageException' => __DIR__ . '/includes/api/ApiMain.php',
+       'UsageException' => __DIR__ . '/includes/api/ApiUsageException.php',
        'User' => __DIR__ . '/includes/user/User.php',
        'UserArray' => __DIR__ . '/includes/user/UserArray.php',
        'UserArrayFromResult' => __DIR__ . '/includes/user/UserArrayFromResult.php',
index 19ca238..f57b9ce 100644 (file)
@@ -25,7 +25,7 @@
                "ext-xml": "*",
                "liuggio/statsd-php-client": "1.0.18",
                "mediawiki/at-ease": "1.1.0",
-               "oojs/oojs-ui": "0.18.1",
+               "oojs/oojs-ui": "0.18.2",
                "oyejorge/less.php": "1.7.0.10",
                "php": ">=5.5.9",
                "psr/log": "1.0.0",
index 0254e06..7efd5d2 100644 (file)
@@ -358,8 +358,12 @@ authenticate and authorize API clients before executing the module. Return
 false and set a message to cancel the request.
 $module: Module object
 $user: Current user
-&$message: API usage message to die with, as a message key or array
-  as accepted by ApiBase::dieUsageMsg.
+&$message: API message to die with. Specific values accepted depend on the
+ MediaWiki version:
+ * 1.29+: IApiMessage, Message, string message key, or key+parameters array to
+   pass to ApiBase::dieWithError().
+ * 1.27+: IApiMessage, or a key or key+parameters in ApiBase::$messageMap.
+ * Earlier: A key or key+parameters in ApiBase::$messageMap.
 
 'APIEditBeforeSave': DEPRECATED! Use EditFilterMergedContent instead.
 Before saving a page with api.php?action=edit, after
@@ -1444,7 +1448,7 @@ true to allow those checks to occur, and false if checking is done.
 &$from: MailAddress object of sending user
 &$subject: subject of the mail
 &$text: text of the mail
-&$error: Out-param for an error
+&$error: Out-param for an error. Should be set to a Status object or boolean false.
 
 'EmailUserCC': Before sending the copy of the email to the author.
 &$to: MailAddress object of receiving user
index 0b65593..b85e1d6 100644 (file)
@@ -73,7 +73,7 @@ class AuthPlugin {
        /**
         * Modify options in the login template.
         *
-        * @param UserLoginTemplate $template
+        * @param BaseTemplate $template
         * @param string $type 'signup' or 'login'. Added in 1.16.
         */
        public function modifyUITemplate( &$template, &$type ) {
index e6223e8..f850152 100644 (file)
@@ -152,7 +152,7 @@ class FileDeleteForm {
         * @param User $user User object performing the request
         * @param array $tags Tags to apply to the deletion action
         * @throws MWException
-        * @return bool|Status
+        * @return Status
         */
        public static function doDelete( &$title, &$file, &$oldimage, $reason,
                $suppress, User $user = null, $tags = []
index fb444bd..052fd16 100644 (file)
@@ -20,6 +20,8 @@
  * @file
  */
 
+use MediaWiki\MediaWikiServices;
+
 /**
  * List for revision table items for a single page
  */
@@ -268,6 +270,14 @@ abstract class RevisionItemBase {
         * This is used to show the list in HTML form, by the special page.
         */
        abstract public function getHTML();
+
+       /**
+        * Returns an instance of LinkRenderer
+        * @return \MediaWiki\Linker\LinkRenderer
+        */
+       protected function getLinkRenderer() {
+               return MediaWikiServices::getInstance()->getLinkRenderer();
+       }
 }
 
 class RevisionList extends RevisionListBase {
index 9f722af..f6631ea 100644 (file)
@@ -36,8 +36,10 @@ if ( !defined( 'MEDIAWIKI' ) ) {
 $fname = 'Setup.php';
 $ps_setup = Profiler::instance()->scopedProfileIn( $fname );
 
-// If any extensions are still queued, force load them
+// Load queued extensions
 ExtensionRegistry::getInstance()->loadFromQueue();
+// Don't let any other extensions load
+ExtensionRegistry::getInstance()->finish();
 
 // Check to see if we are at the file scope
 if ( !isset( $wgVersion ) ) {
index 0c3d52a..cd78b49 100644 (file)
@@ -422,10 +422,7 @@ class WatchedItemQueryService {
                        $ownersToken = $watchlistOwner->getOption( 'watchlisttoken' );
                        $token = $options['watchlistOwnerToken'];
                        if ( $ownersToken == '' || !hash_equals( $ownersToken, $token ) ) {
-                               throw new UsageException(
-                                       'Incorrect watchlist token provided -- please set a correct token in Special:Preferences',
-                                       'bad_wltoken'
-                               );
+                               throw ApiUsageException::newWithMessage( null, 'apierror-bad-watchlist-token', 'bad_wltoken' );
                        }
                        return $watchlistOwner->getId();
                }
index 9573cac..767a163 100644 (file)
@@ -168,7 +168,7 @@ class HistoryAction extends FormlessAction {
                $year = $request->getInt( 'year' );
                $month = $request->getInt( 'month' );
                $tagFilter = $request->getVal( 'tagfilter' );
-               $tagSelector = ChangeTags::buildTagFilterSelector( $tagFilter );
+               $tagSelector = ChangeTags::buildTagFilterSelector( $tagFilter, false, $this->getContext() );
 
                /**
                 * Option to show only revisions that have been (partially) hidden via RevisionDelete
index 2511e3b..5d12590 100644 (file)
@@ -56,8 +56,8 @@ class ApiAMCreateAccount extends ApiBase {
                        $bits = wfParseUrl( $params['returnurl'] );
                        if ( !$bits || $bits['scheme'] === '' ) {
                                $encParamName = $this->encodeParamName( 'returnurl' );
-                               $this->dieUsage(
-                                       "Invalid value '{$params['returnurl']}' for url parameter $encParamName",
+                               $this->dieWithError(
+                                       [ 'apierror-badurl', $encParamName, wfEscapeWikiText( $params['returnurl'] ) ],
                                        "badurl_{$encParamName}"
                                );
                        }
index 6fafebf..5327d7a 100644 (file)
@@ -93,7 +93,7 @@ class ApiAuthManagerHelper {
        /**
         * Call $manager->securitySensitiveOperationStatus()
         * @param string $operation Operation being checked.
-        * @throws UsageException
+        * @throws ApiUsageException
         */
        public function securitySensitiveOperation( $operation ) {
                $status = AuthManager::singleton()->securitySensitiveOperationStatus( $operation );
@@ -102,14 +102,10 @@ class ApiAuthManagerHelper {
                                return;
 
                        case AuthManager::SEC_REAUTH:
-                               $this->module->dieUsage(
-                                       'You have not authenticated recently in this session, please reauthenticate.', 'reauthenticate'
-                               );
+                               $this->module->dieWithError( 'apierror-reauthenticate' );
 
                        case AuthManager::SEC_FAIL:
-                               $this->module->dieUsage(
-                                       'This action is not available as your identify cannot be verified.', 'cannotreauthenticate'
-                               );
+                               $this->module->dieWithError( 'apierror-cannotreauthenticate' );
 
                        default:
                                throw new UnexpectedValueException( "Unknown status \"$status\"" );
index 0cd46e4..a40593f 100644 (file)
@@ -545,7 +545,7 @@ abstract class ApiBase extends ContextSource {
         * @since 1.25
         * @param string $path
         * @return ApiBase|null
-        * @throws UsageException
+        * @throws ApiUsageException
         */
        public function getModuleFromPath( $path ) {
                $module = $this->getMain();
@@ -565,14 +565,14 @@ abstract class ApiBase extends ContextSource {
                        $manager = $parent->getModuleManager();
                        if ( $manager === null ) {
                                $errorPath = implode( '+', array_slice( $parts, 0, $i ) );
-                               $this->dieUsage( "The module \"$errorPath\" has no submodules", 'badmodule' );
+                               $this->dieWithError( [ 'apierror-badmodule-nosubmodules', $errorPath ], 'badmodule' );
                        }
                        $module = $manager->getModule( $parts[$i] );
 
                        if ( $module === null ) {
                                $errorPath = $i ? implode( '+', array_slice( $parts, 0, $i ) ) : $parent->getModuleName();
-                               $this->dieUsage(
-                                       "The module \"$errorPath\" does not have a submodule \"{$parts[$i]}\"",
+                               $this->dieWithError(
+                                       [ 'apierror-badmodule-badsubmodule', $errorPath, wfEscapeWikiText( $parts[$i] ) ],
                                        'badmodule'
                                );
                        }
@@ -670,11 +670,18 @@ abstract class ApiBase extends ContextSource {
        /**
         * This method mangles parameter name based on the prefix supplied to the constructor.
         * Override this method to change parameter name during runtime
-        * @param string $paramName Parameter name
-        * @return string Prefixed parameter name
+        * @param string|string[] $paramName Parameter name
+        * @return string|string[] Prefixed parameter name
+        * @since 1.29 accepts an array of strings
         */
        public function encodeParamName( $paramName ) {
-               return $this->mModulePrefix . $paramName;
+               if ( is_array( $paramName ) ) {
+                       return array_map( function ( $name ) {
+                               return $this->mModulePrefix . $name;
+                       }, $paramName );
+               } else {
+                       return $this->mModulePrefix . $paramName;
+               }
        }
 
        /**
@@ -725,20 +732,32 @@ abstract class ApiBase extends ContextSource {
        public function requireOnlyOneParameter( $params, $required /*...*/ ) {
                $required = func_get_args();
                array_shift( $required );
-               $p = $this->getModulePrefix();
 
                $intersection = array_intersect( array_keys( array_filter( $params,
                        [ $this, 'parameterNotEmpty' ] ) ), $required );
 
                if ( count( $intersection ) > 1 ) {
-                       $this->dieUsage(
-                               "The parameters {$p}" . implode( ", {$p}", $intersection ) . ' can not be used together',
-                               'invalidparammix' );
+                       $this->dieWithError( [
+                               'apierror-invalidparammix',
+                               Message::listParam( array_map(
+                                       function ( $p ) {
+                                               return '<var>' . $this->encodeParamName( $p ) . '</var>';
+                                       },
+                                       array_values( $intersection )
+                               ) ),
+                               count( $intersection ),
+                       ] );
                } elseif ( count( $intersection ) == 0 ) {
-                       $this->dieUsage(
-                               "One of the parameters {$p}" . implode( ", {$p}", $required ) . ' is required',
-                               'missingparam'
-                       );
+                       $this->dieWithError( [
+                               'apierror-missingparam-one-of',
+                               Message::listParam( array_map(
+                                       function ( $p ) {
+                                               return '<var>' . $this->encodeParamName( $p ) . '</var>';
+                                       },
+                                       array_values( $required )
+                               ) ),
+                               count( $required ),
+                       ], 'missingparam' );
                }
        }
 
@@ -751,16 +770,21 @@ abstract class ApiBase extends ContextSource {
        public function requireMaxOneParameter( $params, $required /*...*/ ) {
                $required = func_get_args();
                array_shift( $required );
-               $p = $this->getModulePrefix();
 
                $intersection = array_intersect( array_keys( array_filter( $params,
                        [ $this, 'parameterNotEmpty' ] ) ), $required );
 
                if ( count( $intersection ) > 1 ) {
-                       $this->dieUsage(
-                               "The parameters {$p}" . implode( ", {$p}", $intersection ) . ' can not be used together',
-                               'invalidparammix'
-                       );
+                       $this->dieWithError( [
+                               'apierror-invalidparammix',
+                               Message::listParam( array_map(
+                                       function ( $p ) {
+                                               return '<var>' . $this->encodeParamName( $p ) . '</var>';
+                                       },
+                                       array_values( $intersection )
+                               ) ),
+                               count( $intersection ),
+                       ] );
                }
        }
 
@@ -774,7 +798,6 @@ abstract class ApiBase extends ContextSource {
        public function requireAtLeastOneParameter( $params, $required /*...*/ ) {
                $required = func_get_args();
                array_shift( $required );
-               $p = $this->getModulePrefix();
 
                $intersection = array_intersect(
                        array_keys( array_filter( $params, [ $this, 'parameterNotEmpty' ] ) ),
@@ -782,8 +805,16 @@ abstract class ApiBase extends ContextSource {
                );
 
                if ( count( $intersection ) == 0 ) {
-                       $this->dieUsage( "At least one of the parameters {$p}" .
-                               implode( ", {$p}", $required ) . ' is required', "{$p}missingparam" );
+                       $this->dieWithError( [
+                               'apierror-missingparam-at-least-one-of',
+                               Message::listParam( array_map(
+                                       function ( $p ) {
+                                               return '<var>' . $this->encodeParamName( $p ) . '</var>';
+                                       },
+                                       array_values( $required )
+                               ) ),
+                               count( $required ),
+                       ], 'missingparam' );
                }
        }
 
@@ -812,10 +843,8 @@ abstract class ApiBase extends ContextSource {
                }
 
                if ( $badParams ) {
-                       $this->dieUsage(
-                               'The following parameters were found in the query string, but must be in the POST body: '
-                                       . join( ', ', $badParams ),
-                               'mustpostparams'
+                       $this->dieWithError(
+                               [ 'apierror-mustpostparams', join( ', ', $badParams ), count( $badParams ) ]
                        );
                }
        }
@@ -848,10 +877,10 @@ abstract class ApiBase extends ContextSource {
                if ( isset( $params['title'] ) ) {
                        $titleObj = Title::newFromText( $params['title'] );
                        if ( !$titleObj || $titleObj->isExternal() ) {
-                               $this->dieUsageMsg( [ 'invalidtitle', $params['title'] ] );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $params['title'] ) ] );
                        }
                        if ( !$titleObj->canExist() ) {
-                               $this->dieUsage( "Namespace doesn't allow actual pages", 'pagecannotexist' );
+                               $this->dieWithError( 'apierror-pagecannotexist' );
                        }
                        $pageObj = WikiPage::factory( $titleObj );
                        if ( $load !== false ) {
@@ -863,7 +892,7 @@ abstract class ApiBase extends ContextSource {
                        }
                        $pageObj = WikiPage::newFromID( $params['pageid'], $load );
                        if ( !$pageObj ) {
-                               $this->dieUsageMsg( [ 'nosuchpageid', $params['pageid'] ] );
+                               $this->dieWithError( [ 'apierror-nosuchpageid', $params['pageid'] ] );
                        }
                }
 
@@ -994,10 +1023,8 @@ abstract class ApiBase extends ContextSource {
                                // accidentally uploaded as a field fails spectacularly)
                                $value = $this->getMain()->getRequest()->unsetVal( $encParamName );
                                if ( $value !== null ) {
-                                       $this->dieUsage(
-                                               "File upload param $encParamName is not a file upload; " .
-                                                       'be sure to use multipart/form-data for your POST and include ' .
-                                                       'a filename in the Content-Disposition header.',
+                                       $this->dieWithError(
+                                               [ 'apierror-badupload', $encParamName ],
                                                "badupload_{$encParamName}"
                                        );
                                }
@@ -1032,10 +1059,7 @@ abstract class ApiBase extends ContextSource {
                                        // done by WebRequest for $_GET. Let's call that a feature.
                                        $value = join( "\x1f", $request->normalizeUnicode( explode( "\x1f", $rawValue ) ) );
                                } else {
-                                       $this->dieUsage(
-                                               "U+001F multi-value separation may only be used for multi-valued parameters.",
-                                               'badvalue_notmultivalue'
-                                       );
+                                       $this->dieWithError( 'apierror-badvalue-notmultivalue', 'badvalue_notmultivalue' );
                                }
                        }
 
@@ -1072,7 +1096,7 @@ abstract class ApiBase extends ContextSource {
                                        case 'text':
                                        case 'password':
                                                if ( $required && $value === '' ) {
-                                                       $this->dieUsageMsg( [ 'missingparam', $paramName ] );
+                                                       $this->dieWithError( [ 'apierror-missingparam', $paramName ] );
                                                }
                                                break;
                                        case 'integer': // Force everything using intval() and optionally validate limits
@@ -1175,8 +1199,6 @@ abstract class ApiBase extends ContextSource {
 
                        // Set a warning if a deprecated parameter has been passed
                        if ( $deprecated && $value !== false ) {
-                               $this->setWarning( "The $encParamName parameter has been deprecated." );
-
                                $feature = $encParamName;
                                $m = $this;
                                while ( !$m->isMain() ) {
@@ -1186,10 +1208,10 @@ abstract class ApiBase extends ContextSource {
                                        $feature = "{$param}={$name}&{$feature}";
                                        $m = $p;
                                }
-                               $this->logFeatureUsage( $feature );
+                               $this->addDeprecation( [ 'apiwarn-deprecation-parameter', $encParamName ], $feature );
                        }
                } elseif ( $required ) {
-                       $this->dieUsageMsg( [ 'missingparam', $paramName ] );
+                       $this->dieWithError( [ 'apierror-missingparam', $paramName ] );
                }
 
                return $value;
@@ -1204,11 +1226,7 @@ abstract class ApiBase extends ContextSource {
         */
        protected function handleParamNormalization( $paramName, $value, $rawValue ) {
                $encParamName = $this->encodeParamName( $paramName );
-               $this->setWarning(
-                       "The value passed for '$encParamName' contains invalid or non-normalized data. "
-                       . 'Textual data should be valid, NFC-normalized Unicode without '
-                       . 'C0 control characters other than HT (\\t), LF (\\n), and CR (\\r).'
-               );
+               $this->addWarning( [ 'apiwarn-badutf8', $encParamName ] );
        }
 
        /**
@@ -1265,9 +1283,10 @@ abstract class ApiBase extends ContextSource {
                }
 
                if ( self::truncateArray( $valuesList, $sizeLimit ) ) {
-                       $this->logFeatureUsage( "too-many-$valueName-for-{$this->getModulePath()}" );
-                       $this->setWarning( "Too many values supplied for parameter '$valueName': " .
-                               "the limit is $sizeLimit" );
+                       $this->addDeprecation(
+                               [ 'apiwarn-toomanyvalues', $valueName, $sizeLimit ],
+                               "too-many-$valueName-for-{$this->getModulePath()}"
+                       );
                }
 
                if ( !$allowMultiple && count( $valuesList ) != 1 ) {
@@ -1276,26 +1295,38 @@ abstract class ApiBase extends ContextSource {
                                return $value;
                        }
 
-                       $possibleValues = is_array( $allowedValues )
-                               ? "of '" . implode( "', '", $allowedValues ) . "'"
-                               : '';
-                       $this->dieUsage(
-                               "Only one $possibleValues is allowed for parameter '$valueName'",
-                               "multival_$valueName"
-                       );
+                       if ( is_array( $allowedValues ) ) {
+                               $values = array_map( function ( $v ) {
+                                       return '<kbd>' . wfEscapeWikiText( $v ) . '</kbd>';
+                               }, $allowedValues );
+                               $this->dieWithError( [
+                                       'apierror-multival-only-one-of',
+                                       $valueName,
+                                       Message::listParam( $values ),
+                                       count( $values ),
+                               ], "multival_$valueName" );
+                       } else {
+                               $this->dieWithError( [
+                                       'apierror-multival-only-one',
+                                       $valueName,
+                               ], "multival_$valueName" );
+                       }
                }
 
                if ( is_array( $allowedValues ) ) {
                        // Check for unknown values
-                       $unknown = array_diff( $valuesList, $allowedValues );
+                       $unknown = array_map( 'wfEscapeWikiText', array_diff( $valuesList, $allowedValues ) );
                        if ( count( $unknown ) ) {
                                if ( $allowMultiple ) {
-                                       $s = count( $unknown ) > 1 ? 's' : '';
-                                       $vals = implode( ', ', $unknown );
-                                       $this->setWarning( "Unrecognized value$s for parameter '$valueName': $vals" );
+                                       $this->addWarning( [
+                                               'apiwarn-unrecognizedvalues',
+                                               $valueName,
+                                               Message::listParam( $unknown, 'comma' ),
+                                               count( $unknown ),
+                                       ] );
                                } else {
-                                       $this->dieUsage(
-                                               "Unrecognized value for parameter '$valueName': {$valuesList[0]}",
+                                       $this->dieWithError(
+                                               [ 'apierror-unrecognizedvalue', $valueName, wfEscapeWikiText( $valuesList[0] ) ],
                                                "unknown_$valueName"
                                        );
                                }
@@ -1321,7 +1352,12 @@ abstract class ApiBase extends ContextSource {
                $enforceLimits = false
        ) {
                if ( !is_null( $min ) && $value < $min ) {
-                       $msg = $this->encodeParamName( $paramName ) . " may not be less than $min (set to $value)";
+                       $msg = ApiMessage::create(
+                               [ 'apierror-integeroutofrange-belowminimum',
+                                       $this->encodeParamName( $paramName ), $min, $value ],
+                               'integeroutofrange',
+                               [ 'min' => $min, 'max' => $max, 'botMax' => $botMax ?: $max ]
+                       );
                        $this->warnOrDie( $msg, $enforceLimits );
                        $value = $min;
                }
@@ -1337,13 +1373,22 @@ abstract class ApiBase extends ContextSource {
                if ( !is_null( $max ) && $value > $max ) {
                        if ( !is_null( $botMax ) && $this->getMain()->canApiHighLimits() ) {
                                if ( $value > $botMax ) {
-                                       $msg = $this->encodeParamName( $paramName ) .
-                                               " may not be over $botMax (set to $value) for bots or sysops";
+                                       $msg = ApiMessage::create(
+                                               [ 'apierror-integeroutofrange-abovebotmax',
+                                                       $this->encodeParamName( $paramName ), $botMax, $value ],
+                                               'integeroutofrange',
+                                               [ 'min' => $min, 'max' => $max, 'botMax' => $botMax ?: $max ]
+                                       );
                                        $this->warnOrDie( $msg, $enforceLimits );
                                        $value = $botMax;
                                }
                        } else {
-                               $msg = $this->encodeParamName( $paramName ) . " may not be over $max (set to $value) for users";
+                               $msg = ApiMessage::create(
+                                       [ 'apierror-integeroutofrange-abovemax',
+                                               $this->encodeParamName( $paramName ), $max, $value ],
+                                       'integeroutofrange',
+                                       [ 'min' => $min, 'max' => $max, 'botMax' => $botMax ?: $max ]
+                               );
                                $this->warnOrDie( $msg, $enforceLimits );
                                $value = $max;
                        }
@@ -1361,11 +1406,9 @@ abstract class ApiBase extends ContextSource {
                // (wfTimestamp() also accepts various non-strings and the string of 14
                // ASCII NUL bytes, but those can't get here)
                if ( !$value ) {
-                       $this->logFeatureUsage( 'unclear-"now"-timestamp' );
-                       $this->setWarning(
-                               "Passing '$value' for timestamp parameter $encParamName has been deprecated." .
-                                       ' If for some reason you need to explicitly specify the current time without' .
-                                       ' calculating it client-side, use "now".'
+                       $this->addDeprecation(
+                               [ 'apiwarn-unclearnowtimestamp', $encParamName, wfEscapeWikiText( $value ) ],
+                               'unclear-"now"-timestamp'
                        );
                        return wfTimestamp( TS_MW );
                }
@@ -1377,8 +1420,8 @@ abstract class ApiBase extends ContextSource {
 
                $unixTimestamp = wfTimestamp( TS_UNIX, $value );
                if ( $unixTimestamp === false ) {
-                       $this->dieUsage(
-                               "Invalid value '$value' for timestamp parameter $encParamName",
+                       $this->dieWithError(
+                               [ 'apierror-badtimestamp', $encParamName, wfEscapeWikiText( $value ) ],
                                "badtimestamp_{$encParamName}"
                        );
                }
@@ -1433,8 +1476,8 @@ abstract class ApiBase extends ContextSource {
        private function validateUser( $value, $encParamName ) {
                $title = Title::makeTitleSafe( NS_USER, $value );
                if ( $title === null || $title->hasFragment() ) {
-                       $this->dieUsage(
-                               "Invalid value '$value' for user parameter $encParamName",
+                       $this->dieWithError(
+                               [ 'apierror-baduser', $encParamName, wfEscapeWikiText( $value ) ],
                                "baduser_{$encParamName}"
                        );
                }
@@ -1490,22 +1533,19 @@ abstract class ApiBase extends ContextSource {
                if ( !is_null( $params['owner'] ) && !is_null( $params['token'] ) ) {
                        $user = User::newFromName( $params['owner'], false );
                        if ( !( $user && $user->getId() ) ) {
-                               $this->dieUsage( 'Specified user does not exist', 'bad_wlowner' );
+                               $this->dieWithError(
+                                       [ 'nosuchusershort', wfEscapeWikiText( $params['owner'] ) ], 'bad_wlowner'
+                               );
                        }
                        $token = $user->getOption( 'watchlisttoken' );
                        if ( $token == '' || !hash_equals( $token, $params['token'] ) ) {
-                               $this->dieUsage(
-                                       'Incorrect watchlist token provided -- please set a correct token in Special:Preferences',
-                                       'bad_wltoken'
-                               );
+                               $this->dieWithError( 'apierror-bad-watchlist-token', 'bad_wltoken' );
                        }
                } else {
                        if ( !$this->getUser()->isLoggedIn() ) {
-                               $this->dieUsage( 'You must be logged-in to have a watchlist', 'notloggedin' );
-                       }
-                       if ( !$this->getUser()->isAllowed( 'viewmywatchlist' ) ) {
-                               $this->dieUsage( 'You don\'t have permission to view your watchlist', 'permissiondenied' );
+                               $this->dieWithError( 'watchlistanontext', 'notloggedin' );
                        }
+                       $this->checkUserRightsAny( 'viewmywatchlist' );
                        $user = $this->getUser();
                }
 
@@ -1561,6 +1601,39 @@ abstract class ApiBase extends ContextSource {
                return $msg;
        }
 
+       /**
+        * Turn an array of message keys or key+param arrays into a Status
+        * @since 1.29
+        * @param array $errors
+        * @param User|null $user
+        * @return Status
+        */
+       public function errorArrayToStatus( array $errors, User $user = null ) {
+               if ( $user === null ) {
+                       $user = $this->getUser();
+               }
+
+               $status = Status::newGood();
+               foreach ( $errors as $error ) {
+                       if ( is_array( $error ) && $error[0] === 'blockedtext' && $user->getBlock() ) {
+                               $status->fatal( ApiMessage::create(
+                                       'apierror-blocked',
+                                       'blocked',
+                                       [ 'blockinfo' => ApiQueryUserInfo::getBlockInfo( $user->getBlock() ) ]
+                               ) );
+                       } elseif ( is_array( $error ) && $error[0] === 'autoblockedtext' && $user->getBlock() ) {
+                               $status->fatal( ApiMessage::create(
+                                       'apierror-autoblocked',
+                                       'autoblocked',
+                                       [ 'blockinfo' => ApiQueryUserInfo::getBlockInfo( $user->getBlock() ) ]
+                               ) );
+                       } else {
+                               call_user_func_array( [ $status, 'fatal' ], (array)$error );
+                       }
+               }
+               return $status;
+       }
+
        /**@}*/
 
        /************************************************************************//**
@@ -1569,745 +1642,227 @@ abstract class ApiBase extends ContextSource {
         */
 
        /**
-        * Set warning section for this module. Users should monitor this
-        * section to notice any changes in API. Multiple calls to this
-        * function will result in the warning messages being separated by
-        * newlines
-        * @param string $warning Warning message
+        * Add a warning for this module.
+        *
+        * Users should monitor this section to notice any changes in API. Multiple
+        * calls to this function will result in multiple warning messages.
+        *
+        * If $msg is not an ApiMessage, the message code will be derived from the
+        * message key by stripping any "apiwarn-" or "apierror-" prefix.
+        *
+        * @since 1.29
+        * @param string|array|Message $msg See ApiErrorFormatter::addWarning()
+        * @param string|null $code See ApiErrorFormatter::addWarning()
+        * @param array|null $data See ApiErrorFormatter::addWarning()
         */
-       public function setWarning( $warning ) {
-               $msg = new ApiRawMessage( $warning, 'warning' );
-               $this->getErrorFormatter()->addWarning( $this->getModuleName(), $msg );
+       public function addWarning( $msg, $code = null, $data = null ) {
+               $this->getErrorFormatter()->addWarning( $this->getModulePath(), $msg, $code, $data );
        }
 
        /**
-        * Adds a warning to the output, else dies
+        * Add a deprecation warning for this module.
         *
-        * @param string $msg Message to show as a warning, or error message if dying
-        * @param bool $enforceLimits Whether this is an enforce (die)
+        * A combination of $this->addWarning() and $this->logFeatureUsage()
+        *
+        * @since 1.29
+        * @param string|array|Message $msg See ApiErrorFormatter::addWarning()
+        * @param string|null $feature See ApiBase::logFeatureUsage()
+        * @param array|null $data See ApiErrorFormatter::addWarning()
         */
-       private function warnOrDie( $msg, $enforceLimits = false ) {
-               if ( $enforceLimits ) {
-                       $this->dieUsage( $msg, 'integeroutofrange' );
+       public function addDeprecation( $msg, $feature, $data = [] ) {
+               $data = (array)$data;
+               if ( $feature !== null ) {
+                       $data['feature'] = $feature;
+                       $this->logFeatureUsage( $feature );
                }
+               $this->addWarning( $msg, 'deprecation', $data );
+       }
 
-               $this->setWarning( $msg );
+       /**
+        * Add an error for this module without aborting
+        *
+        * If $msg is not an ApiMessage, the message code will be derived from the
+        * message key by stripping any "apiwarn-" or "apierror-" prefix.
+        *
+        * @note If you want to abort processing, use self::dieWithError() instead.
+        * @since 1.29
+        * @param string|array|Message $msg See ApiErrorFormatter::addError()
+        * @param string|null $code See ApiErrorFormatter::addError()
+        * @param array|null $data See ApiErrorFormatter::addError()
+        */
+       public function addError( $msg, $code = null, $data = null ) {
+               $this->getErrorFormatter()->addError( $this->getModulePath(), $msg, $code, $data );
        }
 
        /**
-        * Throw a UsageException, which will (if uncaught) call the main module's
-        * error handler and die with an error message.
+        * Add warnings and/or errors from a Status
         *
-        * @param string $description One-line human-readable description of the
-        *   error condition, e.g., "The API requires a valid action parameter"
-        * @param string $errorCode Brief, arbitrary, stable string to allow easy
-        *   automated identification of the error, e.g., 'unknown_action'
-        * @param int $httpRespCode HTTP response code
-        * @param array|null $extradata Data to add to the "<error>" element; array in ApiResult format
-        * @throws UsageException always
+        * @note If you want to abort processing, use self::dieStatus() instead.
+        * @since 1.29
+        * @param StatusValue $status
+        * @param string[] $types 'warning' and/or 'error'
         */
-       public function dieUsage( $description, $errorCode, $httpRespCode = 0, $extradata = null ) {
-               throw new UsageException(
-                       $description,
-                       $this->encodeParamName( $errorCode ),
-                       $httpRespCode,
-                       $extradata
-               );
+       public function addMessagesFromStatus( StatusValue $status, $types = [ 'warning', 'error' ] ) {
+               $this->getErrorFormatter()->addMessagesFromStatus( $this->getModulePath(), $status, $types );
+       }
+
+       /**
+        * Abort execution with an error
+        *
+        * If $msg is not an ApiMessage, the message code will be derived from the
+        * message key by stripping any "apiwarn-" or "apierror-" prefix.
+        *
+        * @since 1.29
+        * @param string|array|Message $msg See ApiErrorFormatter::addError()
+        * @param string|null $code See ApiErrorFormatter::addError()
+        * @param array|null $data See ApiErrorFormatter::addError()
+        * @param int|null $httpCode HTTP error code to use
+        * @throws ApiUsageException always
+        */
+       public function dieWithError( $msg, $code = null, $data = null, $httpCode = null ) {
+               throw ApiUsageException::newWithMessage( $this, $msg, $code, $data, $httpCode );
        }
 
        /**
-        * Throw a UsageException, which will (if uncaught) call the main module's
+        * Adds a warning to the output, else dies
+        *
+        * @param ApiMessage $msg Message to show as a warning, or error message if dying
+        * @param bool $enforceLimits Whether this is an enforce (die)
+        */
+       private function warnOrDie( ApiMessage $msg, $enforceLimits = false ) {
+               if ( $enforceLimits ) {
+                       $this->dieWithError( $msg );
+               } else {
+                       $this->addWarning( $msg );
+               }
+       }
+
+       /**
+        * Throw an ApiUsageException, which will (if uncaught) call the main module's
         * error handler and die with an error message including block info.
         *
         * @since 1.27
-        * @param Block $block The block used to generate the UsageException
-        * @throws UsageException always
+        * @param Block $block The block used to generate the ApiUsageException
+        * @throws ApiUsageException always
         */
        public function dieBlocked( Block $block ) {
                // Die using the appropriate message depending on block type
                if ( $block->getType() == Block::TYPE_AUTO ) {
-                       $this->dieUsage(
-                               'Your IP address has been blocked automatically, because it was used by a blocked user',
+                       $this->dieWithError(
+                               'apierror-autoblocked',
                                'autoblocked',
-                               0,
                                [ 'blockinfo' => ApiQueryUserInfo::getBlockInfo( $block ) ]
                        );
                } else {
-                       $this->dieUsage(
-                               'You have been blocked from editing',
+                       $this->dieWithError(
+                               'apierror-blocked',
                                'blocked',
-                               0,
                                [ 'blockinfo' => ApiQueryUserInfo::getBlockInfo( $block ) ]
                        );
                }
        }
 
        /**
-        * Get error (as code, string) from a Status object.
+        * Throw an ApiUsageException based on the Status object.
         *
-        * @since 1.23
-        * @param Status $status
-        * @param array|null &$extraData Set if extra data from IApiMessage is available (since 1.27)
-        * @return array Array of code and error string
-        * @throws MWException
+        * @since 1.22
+        * @since 1.29 Accepts a StatusValue
+        * @param StatusValue $status
+        * @throws ApiUsageException always
         */
-       public function getErrorFromStatus( $status, &$extraData = null ) {
+       public function dieStatus( StatusValue $status ) {
                if ( $status->isGood() ) {
                        throw new MWException( 'Successful status passed to ApiBase::dieStatus' );
                }
 
-               $errors = $status->getErrorsByType( 'error' );
-               if ( !$errors ) {
-                       // No errors? Assume the warnings should be treated as errors
-                       $errors = $status->getErrorsByType( 'warning' );
-               }
-               if ( !$errors ) {
-                       // Still no errors? Punt
-                       $errors = [ [ 'message' => 'unknownerror-nocode', 'params' => [] ] ];
-               }
-
-               // Cannot use dieUsageMsg() because extensions might return custom
-               // error messages.
-               if ( $errors[0]['message'] instanceof Message ) {
-                       $msg = $errors[0]['message'];
-                       if ( $msg instanceof IApiMessage ) {
-                               $extraData = $msg->getApiData();
-                               $code = $msg->getApiCode();
-                       } else {
-                               $code = $msg->getKey();
-                       }
-               } else {
-                       $code = $errors[0]['message'];
-                       $msg = wfMessage( $code, $errors[0]['params'] );
-               }
-               if ( isset( ApiBase::$messageMap[$code] ) ) {
-                       // Translate message to code, for backwards compatibility
-                       $code = ApiBase::$messageMap[$code]['code'];
-               }
-
-               return [ $code, $msg->inLanguage( 'en' )->useDatabase( false )->plain() ];
+               throw new ApiUsageException( $this, $status );
        }
 
-       /**
-        * Throw a UsageException based on the errors in the Status object.
-        *
-        * @since 1.22
-        * @param Status $status
-        * @throws UsageException always
-        */
-       public function dieStatus( $status ) {
-               $extraData = null;
-               list( $code, $msg ) = $this->getErrorFromStatus( $status, $extraData );
-               $this->dieUsage( $msg, $code, 0, $extraData );
-       }
-
-       // @codingStandardsIgnoreStart Allow long lines. Cannot split these.
-       /**
-        * Array that maps message keys to error messages. $1 and friends are replaced.
-        */
-       public static $messageMap = [
-               // This one MUST be present, or dieUsageMsg() will recurse infinitely
-               'unknownerror' => [ 'code' => 'unknownerror', 'info' => "Unknown error: \"\$1\"" ],
-               'unknownerror-nocode' => [ 'code' => 'unknownerror', 'info' => 'Unknown error' ],
-
-               // Messages from Title::getUserPermissionsErrors()
-               'ns-specialprotected' => [
-                       'code' => 'unsupportednamespace',
-                       'info' => "Pages in the Special namespace can't be edited"
-               ],
-               'protectedinterface' => [
-                       'code' => 'protectednamespace-interface',
-                       'info' => "You're not allowed to edit interface messages"
-               ],
-               'namespaceprotected' => [
-                       'code' => 'protectednamespace',
-                       'info' => "You're not allowed to edit pages in the \"\$1\" namespace"
-               ],
-               'customcssprotected' => [
-                       'code' => 'customcssprotected',
-                       'info' => "You're not allowed to edit custom CSS pages"
-               ],
-               'customjsprotected' => [
-                       'code' => 'customjsprotected',
-                       'info' => "You're not allowed to edit custom JavaScript pages"
-               ],
-               'cascadeprotected' => [
-                       'code' => 'cascadeprotected',
-                       'info' => "The page you're trying to edit is protected because it's included in a cascade-protected page"
-               ],
-               'protectedpagetext' => [
-                       'code' => 'protectedpage',
-                       'info' => "The \"\$1\" right is required to edit this page"
-               ],
-               'protect-cantedit' => [
-                       'code' => 'cantedit',
-                       'info' => "You can't protect this page because you can't edit it"
-               ],
-               'deleteprotected' => [
-                       'code' => 'cantedit',
-                       'info' => "You can't delete this page because it has been protected"
-               ],
-               'badaccess-group0' => [
-                       'code' => 'permissiondenied',
-                       'info' => 'Permission denied'
-               ], // Generic permission denied message
-               'badaccess-groups' => [
-                       'code' => 'permissiondenied',
-                       'info' => 'Permission denied'
-               ],
-               'titleprotected' => [
-                       'code' => 'protectedtitle',
-                       'info' => 'This title has been protected from creation'
-               ],
-               'nocreate-loggedin' => [
-                       'code' => 'cantcreate',
-                       'info' => "You don't have permission to create new pages"
-               ],
-               'nocreatetext' => [
-                       'code' => 'cantcreate-anon',
-                       'info' => "Anonymous users can't create new pages"
-               ],
-               'movenologintext' => [
-                       'code' => 'cantmove-anon',
-                       'info' => "Anonymous users can't move pages"
-               ],
-               'movenotallowed' => [
-                       'code' => 'cantmove',
-                       'info' => "You don't have permission to move pages"
-               ],
-               'confirmedittext' => [
-                       'code' => 'confirmemail',
-                       'info' => 'You must confirm your email address before you can edit'
-               ],
-               'blockedtext' => [
-                       'code' => 'blocked',
-                       'info' => 'You have been blocked from editing'
-               ],
-               'autoblockedtext' => [
-                       'code' => 'autoblocked',
-                       'info' => 'Your IP address has been blocked automatically, because it was used by a blocked user'
-               ],
-
-               // Miscellaneous interface messages
-               'actionthrottledtext' => [
-                       'code' => 'ratelimited',
-                       'info' => "You've exceeded your rate limit. Please wait some time and try again"
-               ],
-               'alreadyrolled' => [
-                       'code' => 'alreadyrolled',
-                       'info' => 'The page you tried to rollback was already rolled back'
-               ],
-               'cantrollback' => [
-                       'code' => 'onlyauthor',
-                       'info' => 'The page you tried to rollback only has one author'
-               ],
-               'readonlytext' => [
-                       'code' => 'readonly',
-                       'info' => 'The wiki is currently in read-only mode'
-               ],
-               'sessionfailure' => [
-                       'code' => 'badtoken',
-                       'info' => 'Invalid token' ],
-               'cannotdelete' => [
-                       'code' => 'cantdelete',
-                       'info' => "Couldn't delete \"\$1\". Maybe it was deleted already by someone else"
-               ],
-               'notanarticle' => [
-                       'code' => 'missingtitle',
-                       'info' => "The page you requested doesn't exist"
-               ],
-               'selfmove' => [ 'code' => 'selfmove', 'info' => "Can't move a page to itself"
-               ],
-               'immobile_namespace' => [
-                       'code' => 'immobilenamespace',
-                       'info' => 'You tried to move pages from or to a namespace that is protected from moving'
-               ],
-               'articleexists' => [
-                       'code' => 'articleexists',
-                       'info' => 'The destination article already exists and is not a redirect to the source article'
-               ],
-               'protectedpage' => [
-                       'code' => 'protectedpage',
-                       'info' => "You don't have permission to perform this move"
-               ],
-               'hookaborted' => [
-                       'code' => 'hookaborted',
-                       'info' => 'The modification you tried to make was aborted by an extension hook'
-               ],
-               'cantmove-titleprotected' => [
-                       'code' => 'protectedtitle',
-                       'info' => 'The destination article has been protected from creation'
-               ],
-               'imagenocrossnamespace' => [
-                       'code' => 'nonfilenamespace',
-                       'info' => "Can't move a file to a non-file namespace"
-               ],
-               'imagetypemismatch' => [
-                       'code' => 'filetypemismatch',
-                       'info' => "The new file extension doesn't match its type"
-               ],
-               // 'badarticleerror' => shouldn't happen
-               // 'badtitletext' => shouldn't happen
-               'ip_range_invalid' => [ 'code' => 'invalidrange', 'info' => 'Invalid IP range' ],
-               'range_block_disabled' => [
-                       'code' => 'rangedisabled',
-                       'info' => 'Blocking IP ranges has been disabled'
-               ],
-               'nosuchusershort' => [
-                       'code' => 'nosuchuser',
-                       'info' => "The user you specified doesn't exist"
-               ],
-               'badipaddress' => [ 'code' => 'invalidip', 'info' => 'Invalid IP address specified' ],
-               'ipb_expiry_invalid' => [ 'code' => 'invalidexpiry', 'info' => 'Invalid expiry time' ],
-               'ipb_already_blocked' => [
-                       'code' => 'alreadyblocked',
-                       'info' => 'The user you tried to block was already blocked'
-               ],
-               'ipb_blocked_as_range' => [
-                       'code' => 'blockedasrange',
-                       'info' => "IP address \"\$1\" was blocked as part of range \"\$2\". You can't unblock the IP individually, but you can unblock the range as a whole."
-               ],
-               'ipb_cant_unblock' => [
-                       'code' => 'cantunblock',
-                       'info' => 'The block you specified was not found. It may have been unblocked already'
-               ],
-               'mailnologin' => [
-                       'code' => 'cantsend',
-                       'info' => 'You are not logged in, you do not have a confirmed email address, or you are not allowed to send email to other users, so you cannot send email'
-               ],
-               'ipbblocked' => [
-                       'code' => 'ipbblocked',
-                       'info' => 'You cannot block or unblock users while you are yourself blocked'
-               ],
-               'ipbnounblockself' => [
-                       'code' => 'ipbnounblockself',
-                       'info' => 'You are not allowed to unblock yourself'
-               ],
-               'usermaildisabled' => [
-                       'code' => 'usermaildisabled',
-                       'info' => 'User email has been disabled'
-               ],
-               'blockedemailuser' => [
-                       'code' => 'blockedfrommail',
-                       'info' => 'You have been blocked from sending email'
-               ],
-               'notarget' => [
-                       'code' => 'notarget',
-                       'info' => 'You have not specified a valid target for this action'
-               ],
-               'noemail' => [
-                       'code' => 'noemail',
-                       'info' => 'The user has not specified a valid email address, or has chosen not to receive email from other users'
-               ],
-               'rcpatroldisabled' => [
-                       'code' => 'patroldisabled',
-                       'info' => 'Patrolling is disabled on this wiki'
-               ],
-               'markedaspatrollederror-noautopatrol' => [
-                       'code' => 'noautopatrol',
-                       'info' => "You don't have permission to patrol your own changes"
-               ],
-               'delete-toobig' => [
-                       'code' => 'bigdelete',
-                       'info' => "You can't delete this page because it has more than \$1 revisions"
-               ],
-               'movenotallowedfile' => [
-                       'code' => 'cantmovefile',
-                       'info' => "You don't have permission to move files"
-               ],
-               'userrights-no-interwiki' => [
-                       'code' => 'nointerwikiuserrights',
-                       'info' => "You don't have permission to change user rights on other wikis"
-               ],
-               'userrights-nodatabase' => [
-                       'code' => 'nosuchdatabase',
-                       'info' => "Database \"\$1\" does not exist or is not local"
-               ],
-               'nouserspecified' => [ 'code' => 'invaliduser', 'info' => "Invalid username \"\$1\"" ],
-               'noname' => [ 'code' => 'invaliduser', 'info' => "Invalid username \"\$1\"" ],
-               'summaryrequired' => [ 'code' => 'summaryrequired', 'info' => 'Summary required' ],
-               'import-rootpage-invalid' => [
-                       'code' => 'import-rootpage-invalid',
-                       'info' => 'Root page is an invalid title'
-               ],
-               'import-rootpage-nosubpage' => [
-                       'code' => 'import-rootpage-nosubpage',
-                       'info' => 'Namespace "$1" of the root page does not allow subpages'
-               ],
-
-               // API-specific messages
-               'readrequired' => [
-                       'code' => 'readapidenied',
-                       'info' => 'You need read permission to use this module'
-               ],
-               'writedisabled' => [
-                       'code' => 'noapiwrite',
-                       'info' => "Editing of this wiki through the API is disabled. Make sure the \$wgEnableWriteAPI=true; statement is included in the wiki's LocalSettings.php file"
-               ],
-               'writerequired' => [
-                       'code' => 'writeapidenied',
-                       'info' => "You're not allowed to edit this wiki through the API"
-               ],
-               'missingparam' => [ 'code' => 'no$1', 'info' => "The \$1 parameter must be set" ],
-               'invalidtitle' => [ 'code' => 'invalidtitle', 'info' => "Bad title \"\$1\"" ],
-               'nosuchpageid' => [ 'code' => 'nosuchpageid', 'info' => "There is no page with ID \$1" ],
-               'nosuchrevid' => [ 'code' => 'nosuchrevid', 'info' => "There is no revision with ID \$1" ],
-               'nosuchuser' => [ 'code' => 'nosuchuser', 'info' => "User \"\$1\" doesn't exist" ],
-               'invaliduser' => [ 'code' => 'invaliduser', 'info' => "Invalid username \"\$1\"" ],
-               'invalidexpiry' => [ 'code' => 'invalidexpiry', 'info' => "Invalid expiry time \"\$1\"" ],
-               'pastexpiry' => [ 'code' => 'pastexpiry', 'info' => "Expiry time \"\$1\" is in the past" ],
-               'create-titleexists' => [
-                       'code' => 'create-titleexists',
-                       'info' => "Existing titles can't be protected with 'create'"
-               ],
-               'missingtitle-createonly' => [
-                       'code' => 'missingtitle-createonly',
-                       'info' => "Missing titles can only be protected with 'create'"
-               ],
-               'cantblock' => [ 'code' => 'cantblock',
-                       'info' => "You don't have permission to block users"
-               ],
-               'canthide' => [
-                       'code' => 'canthide',
-                       'info' => "You don't have permission to hide user names from the block log"
-               ],
-               'cantblock-email' => [
-                       'code' => 'cantblock-email',
-                       'info' => "You don't have permission to block users from sending email through the wiki"
-               ],
-               'unblock-notarget' => [
-                       'code' => 'notarget',
-                       'info' => 'Either the id or the user parameter must be set'
-               ],
-               'unblock-idanduser' => [
-                       'code' => 'idanduser',
-                       'info' => "The id and user parameters can't be used together"
-               ],
-               'cantunblock' => [
-                       'code' => 'permissiondenied',
-                       'info' => "You don't have permission to unblock users"
-               ],
-               'cannotundelete' => [
-                       'code' => 'cantundelete',
-                       'info' => "Couldn't undelete: the requested revisions may not exist, or may have been undeleted already"
-               ],
-               'permdenied-undelete' => [
-                       'code' => 'permissiondenied',
-                       'info' => "You don't have permission to restore deleted revisions"
-               ],
-               'createonly-exists' => [
-                       'code' => 'articleexists',
-                       'info' => 'The article you tried to create has been created already'
-               ],
-               'nocreate-missing' => [
-                       'code' => 'missingtitle',
-                       'info' => "The article you tried to edit doesn't exist"
-               ],
-               'cantchangecontentmodel' => [
-                       'code' => 'cantchangecontentmodel',
-                       'info' => "You don't have permission to change the content model of a page"
-               ],
-               'nosuchrcid' => [
-                       'code' => 'nosuchrcid',
-                       'info' => "There is no change with rcid \"\$1\""
-               ],
-               'nosuchlogid' => [
-                       'code' => 'nosuchlogid',
-                       'info' => "There is no log entry with ID \"\$1\""
-               ],
-               'protect-invalidaction' => [
-                       'code' => 'protect-invalidaction',
-                       'info' => "Invalid protection type \"\$1\""
-               ],
-               'protect-invalidlevel' => [
-                       'code' => 'protect-invalidlevel',
-                       'info' => "Invalid protection level \"\$1\""
-               ],
-               'toofewexpiries' => [
-                       'code' => 'toofewexpiries',
-                       'info' => "\$1 expiry timestamps were provided where \$2 were needed"
-               ],
-               'cantimport' => [
-                       'code' => 'cantimport',
-                       'info' => "You don't have permission to import pages"
-               ],
-               'cantimport-upload' => [
-                       'code' => 'cantimport-upload',
-                       'info' => "You don't have permission to import uploaded pages"
-               ],
-               'importnofile' => [ 'code' => 'nofile', 'info' => "You didn't upload a file" ],
-               'importuploaderrorsize' => [
-                       'code' => 'filetoobig',
-                       'info' => 'The file you uploaded is bigger than the maximum upload size'
-               ],
-               'importuploaderrorpartial' => [
-                       'code' => 'partialupload',
-                       'info' => 'The file was only partially uploaded'
-               ],
-               'importuploaderrortemp' => [
-                       'code' => 'notempdir',
-                       'info' => 'The temporary upload directory is missing'
-               ],
-               'importcantopen' => [
-                       'code' => 'cantopenfile',
-                       'info' => "Couldn't open the uploaded file"
-               ],
-               'import-noarticle' => [
-                       'code' => 'badinterwiki',
-                       'info' => 'Invalid interwiki title specified'
-               ],
-               'importbadinterwiki' => [
-                       'code' => 'badinterwiki',
-                       'info' => 'Invalid interwiki title specified'
-               ],
-               'import-unknownerror' => [
-                       'code' => 'import-unknownerror',
-                       'info' => "Unknown error on import: \"\$1\""
-               ],
-               'cantoverwrite-sharedfile' => [
-                       'code' => 'cantoverwrite-sharedfile',
-                       'info' => 'The target file exists on a shared repository and you do not have permission to override it'
-               ],
-               'sharedfile-exists' => [
-                       'code' => 'fileexists-sharedrepo-perm',
-                       'info' => 'The target file exists on a shared repository. Use the ignorewarnings parameter to override it.'
-               ],
-               'mustbeposted' => [
-                       'code' => 'mustbeposted',
-                       'info' => "The \$1 module requires a POST request"
-               ],
-               'show' => [
-                       'code' => 'show',
-                       'info' => 'Incorrect parameter - mutually exclusive values may not be supplied'
-               ],
-               'specialpage-cantexecute' => [
-                       'code' => 'specialpage-cantexecute',
-                       'info' => "You don't have permission to view the results of this special page"
-               ],
-               'invalidoldimage' => [
-                       'code' => 'invalidoldimage',
-                       'info' => 'The oldimage parameter has invalid format'
-               ],
-               'nodeleteablefile' => [
-                       'code' => 'nodeleteablefile',
-                       'info' => 'No such old version of the file'
-               ],
-               'fileexists-forbidden' => [
-                       'code' => 'fileexists-forbidden',
-                       'info' => 'A file with name "$1" already exists, and cannot be overwritten.'
-               ],
-               'fileexists-shared-forbidden' => [
-                       'code' => 'fileexists-shared-forbidden',
-                       'info' => 'A file with name "$1" already exists in the shared file repository, and cannot be overwritten.'
-               ],
-               'filerevert-badversion' => [
-                       'code' => 'filerevert-badversion',
-                       'info' => 'There is no previous local version of this file with the provided timestamp.'
-               ],
-
-               // ApiEditPage messages
-               'noimageredirect-anon' => [
-                       'code' => 'noimageredirect-anon',
-                       'info' => "Anonymous users can't create image redirects"
-               ],
-               'noimageredirect-logged' => [
-                       'code' => 'noimageredirect',
-                       'info' => "You don't have permission to create image redirects"
-               ],
-               'spamdetected' => [
-                       'code' => 'spamdetected',
-                       'info' => "Your edit was refused because it contained a spam fragment: \"\$1\""
-               ],
-               'contenttoobig' => [
-                       'code' => 'contenttoobig',
-                       'info' => "The content you supplied exceeds the article size limit of \$1 kilobytes"
-               ],
-               'noedit-anon' => [ 'code' => 'noedit-anon', 'info' => "Anonymous users can't edit pages" ],
-               'noedit' => [ 'code' => 'noedit', 'info' => "You don't have permission to edit pages" ],
-               'wasdeleted' => [
-                       'code' => 'pagedeleted',
-                       'info' => 'The page has been deleted since you fetched its timestamp'
-               ],
-               'blankpage' => [
-                       'code' => 'emptypage',
-                       'info' => 'Creating new, empty pages is not allowed'
-               ],
-               'editconflict' => [ 'code' => 'editconflict', 'info' => 'Edit conflict detected' ],
-               'hashcheckfailed' => [ 'code' => 'badmd5', 'info' => 'The supplied MD5 hash was incorrect' ],
-               'missingtext' => [
-                       'code' => 'notext',
-                       'info' => 'One of the text, appendtext, prependtext and undo parameters must be set'
-               ],
-               'emptynewsection' => [
-                       'code' => 'emptynewsection',
-                       'info' => 'Creating empty new sections is not possible.'
-               ],
-               'revwrongpage' => [
-                       'code' => 'revwrongpage',
-                       'info' => "r\$1 is not a revision of \"\$2\""
-               ],
-               'undo-failure' => [
-                       'code' => 'undofailure',
-                       'info' => 'Undo failed due to conflicting intermediate edits'
-               ],
-               'content-not-allowed-here' => [
-                       'code' => 'contentnotallowedhere',
-                       'info' => 'Content model "$1" is not allowed at title "$2"'
-               ],
-
-               // Messages from WikiPage::doEit(]
-               'edit-hook-aborted' => [
-                       'code' => 'edit-hook-aborted',
-                       'info' => 'Your edit was aborted by an ArticleSave hook'
-               ],
-               'edit-gone-missing' => [
-                       'code' => 'edit-gone-missing',
-                       'info' => "The page you tried to edit doesn't seem to exist anymore"
-               ],
-               'edit-conflict' => [ 'code' => 'editconflict', 'info' => 'Edit conflict detected' ],
-               'edit-already-exists' => [
-                       'code' => 'edit-already-exists',
-                       'info' => 'It seems the page you tried to create already exist'
-               ],
-
-               // uploadMsgs
-               'invalid-file-key' => [ 'code' => 'invalid-file-key', 'info' => 'Not a valid file key' ],
-               'nouploadmodule' => [ 'code' => 'nouploadmodule', 'info' => 'No upload module set' ],
-               'uploaddisabled' => [
-                       'code' => 'uploaddisabled',
-                       'info' => 'Uploads are not enabled. Make sure $wgEnableUploads is set to true in LocalSettings.php and the PHP ini setting file_uploads is true'
-               ],
-               'copyuploaddisabled' => [
-                       'code' => 'copyuploaddisabled',
-                       'info' => 'Uploads by URL is not enabled. Make sure $wgAllowCopyUploads is set to true in LocalSettings.php.'
-               ],
-               'copyuploadbaddomain' => [
-                       'code' => 'copyuploadbaddomain',
-                       'info' => 'Uploads by URL are not allowed from this domain.'
-               ],
-               'copyuploadbadurl' => [
-                       'code' => 'copyuploadbadurl',
-                       'info' => 'Upload not allowed from this URL.'
-               ],
-
-               'filename-tooshort' => [
-                       'code' => 'filename-tooshort',
-                       'info' => 'The filename is too short'
-               ],
-               'filename-toolong' => [ 'code' => 'filename-toolong', 'info' => 'The filename is too long' ],
-               'illegal-filename' => [
-                       'code' => 'illegal-filename',
-                       'info' => 'The filename is not allowed'
-               ],
-               'filetype-missing' => [
-                       'code' => 'filetype-missing',
-                       'info' => 'The file is missing an extension'
-               ],
-
-               'mustbeloggedin' => [ 'code' => 'mustbeloggedin', 'info' => 'You must be logged in to $1.' ]
-       ];
-       // @codingStandardsIgnoreEnd
-
        /**
         * Helper function for readonly errors
         *
-        * @throws UsageException always
+        * @throws ApiUsageException always
         */
        public function dieReadOnly() {
-               $parsed = $this->parseMsg( [ 'readonlytext' ] );
-               $this->dieUsage( $parsed['info'], $parsed['code'], /* http error */ 0,
-                       [ 'readonlyreason' => wfReadOnlyReason() ] );
+               $this->dieWithError(
+                       'apierror-readonly',
+                       'readonly',
+                       [ 'readonlyreason' => wfReadOnlyReason() ]
+               );
        }
 
        /**
-        * Output the error message related to a certain array
-        * @param array|string|MessageSpecifier $error Element of a getUserPermissionsErrors()-style array
-        * @throws UsageException always
+        * Helper function for permission-denied errors
+        * @since 1.29
+        * @param string|string[] $rights
+        * @param User|null $user
+        * @throws ApiUsageException if the user doesn't have any of the rights.
+        *  The error message is based on $rights[0].
         */
-       public function dieUsageMsg( $error ) {
-               # most of the time we send a 1 element, so we might as well send it as
-               # a string and make this an array here.
-               if ( is_string( $error ) ) {
-                       $error = [ $error ];
+       public function checkUserRightsAny( $rights, $user = null ) {
+               if ( !$user ) {
+                       $user = $this->getUser();
+               }
+               $rights = (array)$rights;
+               if ( !call_user_func_array( [ $user, 'isAllowedAny' ], $rights ) ) {
+                       $this->dieWithError( [ 'apierror-permissiondenied', $this->msg( "action-{$rights[0]}" ) ] );
                }
-               $parsed = $this->parseMsg( $error );
-               $extraData = isset( $parsed['data'] ) ? $parsed['data'] : null;
-               $this->dieUsage( $parsed['info'], $parsed['code'], 0, $extraData );
        }
 
        /**
-        * Will only set a warning instead of failing if the global $wgDebugAPI
-        * is set to true. Otherwise behaves exactly as dieUsageMsg().
-        * @param array|string|MessageSpecifier $error Element of a getUserPermissionsErrors()-style array
-        * @throws UsageException
-        * @since 1.21
+        * Helper function for permission-denied errors
+        * @since 1.29
+        * @param Title $title
+        * @param string|string[] $actions
+        * @param User|null $user
+        * @throws ApiUsageException if the user doesn't have all of the rights.
         */
-       public function dieUsageMsgOrDebug( $error ) {
-               if ( $this->getConfig()->get( 'DebugAPI' ) !== true ) {
-                       $this->dieUsageMsg( $error );
+       public function checkTitleUserPermissions( Title $title, $actions, $user = null ) {
+               if ( !$user ) {
+                       $user = $this->getUser();
                }
 
-               if ( is_string( $error ) ) {
-                       $error = [ $error ];
+               $errors = [];
+               foreach ( (array)$actions as $action ) {
+                       $errors = array_merge( $errors, $title->getUserPermissionsErrors( $action, $user ) );
+               }
+               if ( $errors ) {
+                       $this->dieStatus( $this->errorArrayToStatus( $errors, $user ) );
                }
-               $parsed = $this->parseMsg( $error );
-               $this->setWarning( '$wgDebugAPI: ' . $parsed['code'] . ' - ' . $parsed['info'] );
        }
 
        /**
-        * Die with the $prefix.'badcontinue' error. This call is common enough to
-        * make it into the base method.
-        * @param bool $condition Will only die if this value is true
-        * @throws UsageException
-        * @since 1.21
+        * Will only set a warning instead of failing if the global $wgDebugAPI
+        * is set to true. Otherwise behaves exactly as self::dieWithError().
+        *
+        * @since 1.29
+        * @param string|array|Message $msg
+        * @param string|null $code
+        * @param array|null $data
+        * @param int|null $httpCode
+        * @throws ApiUsageException
         */
-       protected function dieContinueUsageIf( $condition ) {
-               if ( $condition ) {
-                       $this->dieUsage(
-                               'Invalid continue param. You should pass the original value returned by the previous query',
-                               'badcontinue' );
+       public function dieWithErrorOrDebug( $msg, $code = null, $data = null, $httpCode = null ) {
+               if ( $this->getConfig()->get( 'DebugAPI' ) !== true ) {
+                       $this->dieWithError( $msg, $code, $data, $httpCode );
+               } else {
+                       $this->addWarning( $msg, $code, $data );
                }
        }
 
        /**
-        * Return the error message related to a certain array
-        * @param array|string|MessageSpecifier $error Element of a getUserPermissionsErrors()-style array
-        * @return [ 'code' => code, 'info' => info ]
+        * Die with the 'badcontinue' error.
+        *
+        * This call is common enough to make it into the base method.
+        *
+        * @param bool $condition Will only die if this value is true
+        * @throws ApiUsageException
+        * @since 1.21
         */
-       public function parseMsg( $error ) {
-               // Check whether someone passed the whole array, instead of one element as
-               // documented. This breaks if it's actually an array of fallback keys, but
-               // that's long-standing misbehavior introduced in r87627 to incorrectly
-               // fix T30797.
-               if ( is_array( $error ) ) {
-                       $first = reset( $error );
-                       if ( is_array( $first ) ) {
-                               wfDebug( __METHOD__ . ' was passed an array of arrays. ' . wfGetAllCallers( 5 ) );
-                               $error = $first;
-                       }
-               }
-
-               $msg = Message::newFromSpecifier( $error );
-
-               if ( $msg instanceof IApiMessage ) {
-                       return [
-                               'code' => $msg->getApiCode(),
-                               'info' => $msg->inLanguage( 'en' )->useDatabase( false )->text(),
-                               'data' => $msg->getApiData()
-                       ];
-               }
-
-               $key = $msg->getKey();
-               if ( isset( self::$messageMap[$key] ) ) {
-                       $params = $msg->getParams();
-                       return [
-                               'code' => wfMsgReplaceArgs( self::$messageMap[$key]['code'], $params ),
-                               'info' => wfMsgReplaceArgs( self::$messageMap[$key]['info'], $params )
-                       ];
+       protected function dieContinueUsageIf( $condition ) {
+               if ( $condition ) {
+                       $this->dieWithError( 'apierror-badcontinue' );
                }
-
-               // If the key isn't present, throw an "unknown error"
-               return $this->parseMsg( [ 'unknownerror', $key ] );
        }
 
        /**
@@ -2323,6 +1878,7 @@ abstract class ApiBase extends ContextSource {
        /**
         * Write logging information for API features to a debug log, for usage
         * analysis.
+        * @note Consider using $this->addDeprecation() instead to both warn and log.
         * @param string $feature Feature being used.
         */
        public function logFeatureUsage( $feature ) {
@@ -2790,6 +2346,300 @@ abstract class ApiBase extends ContextSource {
                }
        }
 
+       /**
+        * @deprecated since 1.29, use ApiBase::addWarning() instead
+        * @param string $warning Warning message
+        */
+       public function setWarning( $warning ) {
+               $msg = new ApiRawMessage( $warning, 'warning' );
+               $this->getErrorFormatter()->addWarning( $this->getModulePath(), $msg );
+       }
+
+       /**
+        * Throw an ApiUsageException, which will (if uncaught) call the main module's
+        * error handler and die with an error message.
+        *
+        * @deprecated since 1.29, use self::dieWithError() instead
+        * @param string $description One-line human-readable description of the
+        *   error condition, e.g., "The API requires a valid action parameter"
+        * @param string $errorCode Brief, arbitrary, stable string to allow easy
+        *   automated identification of the error, e.g., 'unknown_action'
+        * @param int $httpRespCode HTTP response code
+        * @param array|null $extradata Data to add to the "<error>" element; array in ApiResult format
+        * @throws ApiUsageException always
+        */
+       public function dieUsage( $description, $errorCode, $httpRespCode = 0, $extradata = null ) {
+               $this->dieWithError(
+                       new RawMessage( '$1', [ $description ] ),
+                       $errorCode,
+                       $extradata,
+                       $httpRespCode
+               );
+       }
+
+       /**
+        * Get error (as code, string) from a Status object.
+        *
+        * @since 1.23
+        * @deprecated since 1.29, use ApiErrorFormatter::arrayFromStatus instead
+        * @param Status $status
+        * @param array|null &$extraData Set if extra data from IApiMessage is available (since 1.27)
+        * @return array Array of code and error string
+        * @throws MWException
+        */
+       public function getErrorFromStatus( $status, &$extraData = null ) {
+               if ( $status->isGood() ) {
+                       throw new MWException( 'Successful status passed to ApiBase::dieStatus' );
+               }
+
+               $errors = $status->getErrorsByType( 'error' );
+               if ( !$errors ) {
+                       // No errors? Assume the warnings should be treated as errors
+                       $errors = $status->getErrorsByType( 'warning' );
+               }
+               if ( !$errors ) {
+                       // Still no errors? Punt
+                       $errors = [ [ 'message' => 'unknownerror-nocode', 'params' => [] ] ];
+               }
+
+               if ( $errors[0]['message'] instanceof MessageSpecifier ) {
+                       $msg = $errors[0]['message'];
+               } else {
+                       $msg = new Message( $errors[0]['message'], $errors[0]['params'] );
+               }
+               if ( !$msg instanceof IApiMessage ) {
+                       $key = $msg->getKey();
+                       $params = $msg->getParams();
+                       array_unshift( $params, isset( self::$messageMap[$key] ) ? self::$messageMap[$key] : $key );
+                       $msg = ApiMessage::create( $params );
+               }
+
+               return [
+                       $msg->getApiCode(),
+                       ApiErrorFormatter::stripMarkup( $msg->inLanguage( 'en' )->useDatabase( false )->text() )
+               ];
+       }
+
+       /**
+        * @deprecated since 1.29. Prior to 1.29, this was a public mapping from
+        *  arbitrary strings (often message keys used elsewhere in MediaWiki) to
+        *  API codes and message texts, and a few interfaces required poking
+        *  something in here. Now we're repurposing it to map those same strings
+        *  to i18n messages, and declaring that any interface that requires poking
+        *  at this is broken and needs replacing ASAP.
+        */
+       private static $messageMap = [
+               'unknownerror' => 'apierror-unknownerror',
+               'unknownerror-nocode' => 'apierror-unknownerror-nocode',
+               'ns-specialprotected' => 'ns-specialprotected',
+               'protectedinterface' => 'protectedinterface',
+               'namespaceprotected' => 'namespaceprotected',
+               'customcssprotected' => 'customcssprotected',
+               'customjsprotected' => 'customjsprotected',
+               'cascadeprotected' => 'cascadeprotected',
+               'protectedpagetext' => 'protectedpagetext',
+               'protect-cantedit' => 'protect-cantedit',
+               'deleteprotected' => 'deleteprotected',
+               'badaccess-group0' => 'badaccess-group0',
+               'badaccess-groups' => 'badaccess-groups',
+               'titleprotected' => 'titleprotected',
+               'nocreate-loggedin' => 'nocreate-loggedin',
+               'nocreatetext' => 'nocreatetext',
+               'movenologintext' => 'movenologintext',
+               'movenotallowed' => 'movenotallowed',
+               'confirmedittext' => 'confirmedittext',
+               'blockedtext' => 'apierror-blocked',
+               'autoblockedtext' => 'apierror-autoblocked',
+               'actionthrottledtext' => 'apierror-ratelimited',
+               'alreadyrolled' => 'alreadyrolled',
+               'cantrollback' => 'cantrollback',
+               'readonlytext' => 'readonlytext',
+               'sessionfailure' => 'sessionfailure',
+               'cannotdelete' => 'cannotdelete',
+               'notanarticle' => 'apierror-missingtitle',
+               'selfmove' => 'selfmove',
+               'immobile_namespace' => 'apierror-immobilenamespace',
+               'articleexists' => 'articleexists',
+               'hookaborted' => 'hookaborted',
+               'cantmove-titleprotected' => 'cantmove-titleprotected',
+               'imagenocrossnamespace' => 'imagenocrossnamespace',
+               'imagetypemismatch' => 'imagetypemismatch',
+               'ip_range_invalid' => 'ip_range_invalid',
+               'range_block_disabled' => 'range_block_disabled',
+               'nosuchusershort' => 'nosuchusershort',
+               'badipaddress' => 'badipaddress',
+               'ipb_expiry_invalid' => 'ipb_expiry_invalid',
+               'ipb_already_blocked' => 'ipb_already_blocked',
+               'ipb_blocked_as_range' => 'ipb_blocked_as_range',
+               'ipb_cant_unblock' => 'ipb_cant_unblock',
+               'mailnologin' => 'apierror-cantsend',
+               'ipbblocked' => 'ipbblocked',
+               'ipbnounblockself' => 'ipbnounblockself',
+               'usermaildisabled' => 'usermaildisabled',
+               'blockedemailuser' => 'apierror-blockedfrommail',
+               'notarget' => 'apierror-notarget',
+               'noemail' => 'noemail',
+               'rcpatroldisabled' => 'rcpatroldisabled',
+               'markedaspatrollederror-noautopatrol' => 'markedaspatrollederror-noautopatrol',
+               'delete-toobig' => 'delete-toobig',
+               'movenotallowedfile' => 'movenotallowedfile',
+               'userrights-no-interwiki' => 'userrights-no-interwiki',
+               'userrights-nodatabase' => 'userrights-nodatabase',
+               'nouserspecified' => 'nouserspecified',
+               'noname' => 'noname',
+               'summaryrequired' => 'apierror-summaryrequired',
+               'import-rootpage-invalid' => 'import-rootpage-invalid',
+               'import-rootpage-nosubpage' => 'import-rootpage-nosubpage',
+               'readrequired' => 'apierror-readapidenied',
+               'writedisabled' => 'apierror-noapiwrite',
+               'writerequired' => 'apierror-writeapidenied',
+               'missingparam' => 'apierror-missingparam',
+               'invalidtitle' => 'apierror-invalidtitle',
+               'nosuchpageid' => 'apierror-nosuchpageid',
+               'nosuchrevid' => 'apierror-nosuchrevid',
+               'nosuchuser' => 'nosuchusershort',
+               'invaliduser' => 'apierror-invaliduser',
+               'invalidexpiry' => 'apierror-invalidexpiry',
+               'pastexpiry' => 'apierror-pastexpiry',
+               'create-titleexists' => 'apierror-create-titleexists',
+               'missingtitle-createonly' => 'apierror-missingtitle-createonly',
+               'cantblock' => 'apierror-cantblock',
+               'canthide' => 'apierror-canthide',
+               'cantblock-email' => 'apierror-cantblock-email',
+               'cantunblock' => 'apierror-permissiondenied-generic',
+               'cannotundelete' => 'cannotundelete',
+               'permdenied-undelete' => 'apierror-permissiondenied-generic',
+               'createonly-exists' => 'apierror-articleexists',
+               'nocreate-missing' => 'apierror-missingtitle',
+               'cantchangecontentmodel' => 'apierror-cantchangecontentmodel',
+               'nosuchrcid' => 'apierror-nosuchrcid',
+               'nosuchlogid' => 'apierror-nosuchlogid',
+               'protect-invalidaction' => 'apierror-protect-invalidaction',
+               'protect-invalidlevel' => 'apierror-protect-invalidlevel',
+               'toofewexpiries' => 'apierror-toofewexpiries',
+               'cantimport' => 'apierror-cantimport',
+               'cantimport-upload' => 'apierror-cantimport-upload',
+               'importnofile' => 'importnofile',
+               'importuploaderrorsize' => 'importuploaderrorsize',
+               'importuploaderrorpartial' => 'importuploaderrorpartial',
+               'importuploaderrortemp' => 'importuploaderrortemp',
+               'importcantopen' => 'importcantopen',
+               'import-noarticle' => 'import-noarticle',
+               'importbadinterwiki' => 'importbadinterwiki',
+               'import-unknownerror' => 'apierror-import-unknownerror',
+               'cantoverwrite-sharedfile' => 'apierror-cantoverwrite-sharedfile',
+               'sharedfile-exists' => 'apierror-fileexists-sharedrepo-perm',
+               'mustbeposted' => 'apierror-mustbeposted',
+               'show' => 'apierror-show',
+               'specialpage-cantexecute' => 'apierror-specialpage-cantexecute',
+               'invalidoldimage' => 'apierror-invalidoldimage',
+               'nodeleteablefile' => 'apierror-nodeleteablefile',
+               'fileexists-forbidden' => 'fileexists-forbidden',
+               'fileexists-shared-forbidden' => 'fileexists-shared-forbidden',
+               'filerevert-badversion' => 'filerevert-badversion',
+               'noimageredirect-anon' => 'apierror-noimageredirect-anon',
+               'noimageredirect-logged' => 'apierror-noimageredirect',
+               'spamdetected' => 'apierror-spamdetected',
+               'contenttoobig' => 'apierror-contenttoobig',
+               'noedit-anon' => 'apierror-noedit-anon',
+               'noedit' => 'apierror-noedit',
+               'wasdeleted' => 'apierror-pagedeleted',
+               'blankpage' => 'apierror-emptypage',
+               'editconflict' => 'editconflict',
+               'hashcheckfailed' => 'apierror-badmd5',
+               'missingtext' => 'apierror-notext',
+               'emptynewsection' => 'apierror-emptynewsection',
+               'revwrongpage' => 'apierror-revwrongpage',
+               'undo-failure' => 'undo-failure',
+               'content-not-allowed-here' => 'content-not-allowed-here',
+               'edit-hook-aborted' => 'edit-hook-aborted',
+               'edit-gone-missing' => 'edit-gone-missing',
+               'edit-conflict' => 'edit-conflict',
+               'edit-already-exists' => 'edit-already-exists',
+               'invalid-file-key' => 'apierror-invalid-file-key',
+               'nouploadmodule' => 'apierror-nouploadmodule',
+               'uploaddisabled' => 'uploaddisabled',
+               'copyuploaddisabled' => 'copyuploaddisabled',
+               'copyuploadbaddomain' => 'apierror-copyuploadbaddomain',
+               'copyuploadbadurl' => 'apierror-copyuploadbadurl',
+               'filename-tooshort' => 'filename-tooshort',
+               'filename-toolong' => 'filename-toolong',
+               'illegal-filename' => 'illegal-filename',
+               'filetype-missing' => 'filetype-missing',
+               'mustbeloggedin' => 'apierror-mustbeloggedin',
+       ];
+
+       /**
+        * @deprecated do not use
+        * @param array|string|MessageSpecifier $error Element of a getUserPermissionsErrors()-style array
+        * @return ApiMessage
+        */
+       private function parseMsgInternal( $error ) {
+               $msg = Message::newFromSpecifier( $error );
+               if ( !$msg instanceof IApiMessage ) {
+                       $key = $msg->getKey();
+                       if ( isset( self::$messageMap[$key] ) ) {
+                               $params = $msg->getParams();
+                               array_unshift( $params, self::$messageMap[$key] );
+                       } else {
+                               $params = [ 'apierror-unknownerror', wfEscapeWikiText( $key ) ];
+                       }
+                       $msg = ApiMessage::create( $params );
+               }
+               return $msg;
+       }
+
+       /**
+        * Return the error message related to a certain array
+        * @deprecated since 1.29
+        * @param array|string|MessageSpecifier $error Element of a getUserPermissionsErrors()-style array
+        * @return [ 'code' => code, 'info' => info ]
+        */
+       public function parseMsg( $error ) {
+               // Check whether someone passed the whole array, instead of one element as
+               // documented. This breaks if it's actually an array of fallback keys, but
+               // that's long-standing misbehavior introduced in r87627 to incorrectly
+               // fix T30797.
+               if ( is_array( $error ) ) {
+                       $first = reset( $error );
+                       if ( is_array( $first ) ) {
+                               wfDebug( __METHOD__ . ' was passed an array of arrays. ' . wfGetAllCallers( 5 ) );
+                               $error = $first;
+                       }
+               }
+
+               $msg = $this->parseMsgInternal( $error );
+               return [
+                       'code' => $msg->getApiCode(),
+                       'info' => ApiErrorFormatter::stripMarkup(
+                               $msg->inLanguage( 'en' )->useDatabase( false )->text()
+                       ),
+                       'data' => $msg->getApiData()
+               ];
+       }
+
+       /**
+        * Output the error message related to a certain array
+        * @deprecated since 1.29, use ApiBase::dieWithError() instead
+        * @param array|string|MessageSpecifier $error Element of a getUserPermissionsErrors()-style array
+        * @throws ApiUsageException always
+        */
+       public function dieUsageMsg( $error ) {
+               $this->dieWithError( $this->parseMsgInternal( $error ) );
+       }
+
+       /**
+        * Will only set a warning instead of failing if the global $wgDebugAPI
+        * is set to true. Otherwise behaves exactly as dieUsageMsg().
+        * @deprecated since 1.29, use ApiBase::dieWithErrorOrDebug() instead
+        * @param array|string|MessageSpecifier $error Element of a getUserPermissionsErrors()-style array
+        * @throws ApiUsageException
+        * @since 1.21
+        */
+       public function dieUsageMsgOrDebug( $error ) {
+               $this->dieWithErrorOrDebug( $this->parseMsgInternal( $error ) );
+       }
+
        /**@}*/
 }
 
index e4c9d0a..a4ea385 100644 (file)
@@ -41,22 +41,18 @@ class ApiBlock extends ApiBase {
        public function execute() {
                global $wgContLang;
 
+               $this->checkUserRightsAny( 'block' );
+
                $user = $this->getUser();
                $params = $this->extractRequestParams();
 
-               if ( !$user->isAllowed( 'block' ) ) {
-                       $this->dieUsageMsg( 'cantblock' );
-               }
-
                # bug 15810: blocked admins should have limited access here
                if ( $user->isBlocked() ) {
                        $status = SpecialBlock::checkUnblockSelf( $params['user'], $user );
                        if ( $status !== true ) {
-                               $msg = $this->parseMsg( $status );
-                               $this->dieUsage(
-                                       $msg['info'],
-                                       $msg['code'],
-                                       0,
+                               $this->dieWithError(
+                                       $status,
+                                       null,
                                        [ 'blockinfo' => ApiQueryUserInfo::getBlockInfo( $user->getBlock() ) ]
                                );
                        }
@@ -68,14 +64,14 @@ class ApiBlock extends ApiBase {
                if ( $target instanceof User &&
                        ( $target->isAnon() /* doesn't exist */ || !User::isUsableName( $target->getName() ) )
                ) {
-                       $this->dieUsageMsg( [ 'nosuchuser', $params['user'] ] );
+                       $this->dieWithError( [ 'nosuchusershort', $params['user'] ], 'nosuchuser' );
                }
 
                if ( $params['hidename'] && !$user->isAllowed( 'hideuser' ) ) {
-                       $this->dieUsageMsg( 'canthide' );
+                       $this->dieWithError( 'apierror-canthide' );
                }
                if ( $params['noemail'] && !SpecialBlock::canBlockEmail( $user ) ) {
-                       $this->dieUsageMsg( 'cantblock-email' );
+                       $this->dieWithError( 'apierror-cantblock-email' );
                }
 
                $data = [
@@ -100,8 +96,7 @@ class ApiBlock extends ApiBase {
 
                $retval = SpecialBlock::processForm( $data, $this->getContext() );
                if ( $retval !== true ) {
-                       // We don't care about multiple errors, just report one of them
-                       $this->dieUsageMsg( $retval );
+                       $this->dieStatus( $this->errorArrayToStatus( $retval ) );
                }
 
                list( $target, /*...*/ ) = SpecialBlock::getTargetAndType( $params['user'] );
index 5a0edfc..4139019 100644 (file)
@@ -137,8 +137,11 @@ class ApiCSPReport extends ApiBase {
                }
                $status = FormatJson::parse( $postBody, FormatJson::FORCE_ASSOC );
                if ( !$status->isGood() ) {
-                       list( $code, ) = $this->getErrorFromStatus( $status );
-                       $this->error( $code, __METHOD__ );
+                       $msg = $status->getErrors()[0]['message'];
+                       if ( $msg instanceof Message ) {
+                               $msg = $msg->getKey();
+                       }
+                       $this->error( $msg, __METHOD__ );
                }
 
                $report = $status->getValue();
@@ -176,7 +179,7 @@ class ApiCSPReport extends ApiBase {
         *
         * @param $code String error code
         * @param $method String method that made error
-        * @throws UsageException Always
+        * @throws ApiUsageException Always
         */
        private function error( $code, $method ) {
                $this->log->info( 'Error reading CSP report: ' . $code, [
@@ -184,7 +187,9 @@ class ApiCSPReport extends ApiBase {
                        'user-agent' => $this->getRequest()->getHeader( 'user-agent' )
                ] );
                // 500 so it shows up in browser's developer console.
-               $this->dieUsage( "Error processing CSP report: $code", 'cspreport-' . $code, 500 );
+               $this->dieWithError(
+                       [ 'apierror-csp-report', wfEscapeWikiText( $code ) ], 'cspreport-' . $code, [], 500
+               );
        }
 
        public function getAllowedParams() {
index aea2819..c25920e 100644 (file)
@@ -35,7 +35,7 @@ class ApiChangeAuthenticationData extends ApiBase {
 
        public function execute() {
                if ( !$this->getUser()->isLoggedIn() ) {
-                       $this->dieUsage( 'Must be logged in to change authentication data', 'notloggedin' );
+                       $this->dieWithError( 'apierror-mustbeloggedin-changeauthenticationdata', 'notloggedin' );
                }
 
                $helper = new ApiAuthManagerHelper( $this );
@@ -50,7 +50,7 @@ class ApiChangeAuthenticationData extends ApiBase {
                        $this->getConfig()->get( 'ChangeCredentialsBlacklist' )
                );
                if ( count( $reqs ) !== 1 ) {
-                       $this->dieUsage( 'Failed to create change request', 'badrequest' );
+                       $this->dieWithError( 'apierror-changeauth-norequest', 'badrequest' );
                }
                $req = reset( $reqs );
 
index dd88b5f..3cc7a8a 100644 (file)
@@ -43,9 +43,7 @@ class ApiCheckToken extends ApiBase {
                );
 
                if ( substr( $token, -strlen( urldecode( Token::SUFFIX ) ) ) === urldecode( Token::SUFFIX ) ) {
-                       $this->setWarning(
-                               "Check that symbols such as \"+\" in the token are properly percent-encoded in the URL."
-                       );
+                       $this->addWarning( 'apiwarn-checktoken-percentencoding' );
                }
 
                if ( $tokenObj->match( $token, $maxage ) ) {
index cbb1524..3f5bc0c 100644 (file)
@@ -57,8 +57,8 @@ class ApiClientLogin extends ApiBase {
                        $bits = wfParseUrl( $params['returnurl'] );
                        if ( !$bits || $bits['scheme'] === '' ) {
                                $encParamName = $this->encodeParamName( 'returnurl' );
-                               $this->dieUsage(
-                                       "Invalid value '{$params['returnurl']}' for url parameter $encParamName",
+                               $this->dieWithError(
+                                       [ 'apierror-badurl', $encParamName, wfEscapeWikiText( $params['returnurl'] ) ],
                                        "badurl_{$encParamName}"
                                );
                        }
index 7eb0bf3..d6867eb 100644 (file)
@@ -34,8 +34,7 @@ class ApiComparePages extends ApiBase {
                $revision = Revision::newFromId( $rev1 );
 
                if ( !$revision ) {
-                       $this->dieUsage( 'The diff cannot be retrieved, ' .
-                               'one revision does not exist or you do not have permission to view it.', 'baddiff' );
+                       $this->dieWithError( 'apierror-baddiff' );
                }
 
                $contentHandler = $revision->getContentHandler();
@@ -65,11 +64,7 @@ class ApiComparePages extends ApiBase {
                $difftext = $de->getDiffBody();
 
                if ( $difftext === false ) {
-                       $this->dieUsage(
-                               'The diff cannot be retrieved. Maybe one or both revisions do ' .
-                                       'not exist or you do not have permission to view them.',
-                               'baddiff'
-                       );
+                       $this->dieWithError( 'apierror-baddiff' );
                }
 
                ApiResult::setContentValue( $vals, 'body', $difftext );
@@ -89,22 +84,19 @@ class ApiComparePages extends ApiBase {
                } elseif ( $titleText ) {
                        $title = Title::newFromText( $titleText );
                        if ( !$title || $title->isExternal() ) {
-                               $this->dieUsageMsg( [ 'invalidtitle', $titleText ] );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $titleText ) ] );
                        }
 
                        return $title->getLatestRevID();
                } elseif ( $titleId ) {
                        $title = Title::newFromID( $titleId );
                        if ( !$title ) {
-                               $this->dieUsageMsg( [ 'nosuchpageid', $titleId ] );
+                               $this->dieWithError( [ 'apierror-nosuchpageid', $titleId ] );
                        }
 
                        return $title->getLatestRevID();
                }
-               $this->dieUsage(
-                       'A title, a page ID, or a revision number is needed for both the from and the to parameters',
-                       'inputneeded'
-               );
+               $this->dieWithError( 'apierror-compare-inputneeded', 'inputneeded' );
        }
 
        public function getAllowedParams() {
index 19e2453..7da8ed9 100644 (file)
@@ -40,7 +40,7 @@ class ApiContinuationManager {
         * @param ApiBase $module Module starting the continuation
         * @param ApiBase[] $allModules Contains ApiBase instances that will be executed
         * @param array $generatedModules Names of modules that depend on the generator
-        * @throws UsageException
+        * @throws ApiUsageException
         */
        public function __construct(
                ApiBase $module, array $allModules = [], array $generatedModules = []
@@ -57,10 +57,7 @@ class ApiContinuationManager {
                if ( $continue !== '' ) {
                        $continue = explode( '||', $continue );
                        if ( count( $continue ) !== 2 ) {
-                               throw new UsageException(
-                                       'Invalid continue param. You should pass the original value returned by the previous query',
-                                       'badcontinue'
-                               );
+                               throw ApiUsageException::newWithMessage( $module->getMain(), 'apierror-badcontinue' );
                        }
                        $this->generatorDone = ( $continue[0] === '-' );
                        $skip = explode( '|', $continue[1] );
index 993c23e..50c24ae 100644 (file)
@@ -45,7 +45,7 @@ class ApiDelete extends ApiBase {
 
                $pageObj = $this->getTitleOrPageId( $params, 'fromdbmaster' );
                if ( !$pageObj->exists() ) {
-                       $this->dieUsageMsg( 'notanarticle' );
+                       $this->dieWithError( 'apierror-missingtitle' );
                }
 
                $titleObj = $pageObj->getTitle();
@@ -53,10 +53,7 @@ class ApiDelete extends ApiBase {
                $user = $this->getUser();
 
                // Check that the user is allowed to carry out the deletion
-               $errors = $titleObj->getUserPermissionsErrors( 'delete', $user );
-               if ( count( $errors ) ) {
-                       $this->dieUsageMsg( $errors[0] );
-               }
+               $this->checkTitleUserPermissions( $titleObj, 'delete' );
 
                // If change tagging was requested, check that the user is allowed to tag,
                // and the tags are valid
@@ -80,9 +77,6 @@ class ApiDelete extends ApiBase {
                        $status = self::delete( $pageObj, $user, $reason, $params['tags'] );
                }
 
-               if ( is_array( $status ) ) {
-                       $this->dieUsageMsg( $status[0] );
-               }
                if ( !$status->isGood() ) {
                        $this->dieStatus( $status );
                }
@@ -112,7 +106,7 @@ class ApiDelete extends ApiBase {
         * @param User $user User doing the action
         * @param string|null $reason Reason for the deletion. Autogenerated if null
         * @param array $tags Tags to tag the deletion with
-        * @return Status|array
+        * @return Status
         */
        protected static function delete( Page $page, User $user, &$reason = null, $tags = [] ) {
                $title = $page->getTitle();
@@ -124,7 +118,7 @@ class ApiDelete extends ApiBase {
                        $hasHistory = false;
                        $reason = $page->getAutoDeleteReason( $hasHistory );
                        if ( $reason === false ) {
-                               return [ [ 'cannotdelete', $title->getPrefixedText() ] ];
+                               return Status::newFatal( 'cannotdelete', $title->getPrefixedText() );
                        }
                }
 
@@ -141,7 +135,7 @@ class ApiDelete extends ApiBase {
         * @param string $reason Reason for the deletion. Autogenerated if null.
         * @param bool $suppress Whether to mark all deleted versions as restricted
         * @param array $tags Tags to tag the deletion with
-        * @return Status|array
+        * @return Status
         */
        protected static function deleteFile( Page $page, User $user, $oldimage,
                &$reason = null, $suppress = false, $tags = []
@@ -155,11 +149,11 @@ class ApiDelete extends ApiBase {
 
                if ( $oldimage ) {
                        if ( !FileDeleteForm::isValidOldSpec( $oldimage ) ) {
-                               return [ [ 'invalidoldimage' ] ];
+                               return Status::newFatal( 'invalidoldimage' );
                        }
                        $oldfile = RepoGroup::singleton()->getLocalRepo()->newFromArchiveName( $title, $oldimage );
                        if ( !$oldfile->exists() || !$oldfile->isLocal() || $oldfile->getRedirected() ) {
-                               return [ [ 'nodeleteablefile' ] ];
+                               return Status::newFatal( 'nodeleteablefile' );
                        }
                }
 
index fc97522..41bf9b6 100644 (file)
@@ -37,7 +37,7 @@
 class ApiDisabled extends ApiBase {
 
        public function execute() {
-               $this->dieUsage( "The \"{$this->getModuleName()}\" module has been disabled.", 'moduledisabled' );
+               $this->dieWithError( [ 'apierror-moduledisabled', $this->getModuleName() ] );
        }
 
        public function isReadMode() {
index d6de834..6b56870 100644 (file)
@@ -40,12 +40,7 @@ class ApiEditPage extends ApiBase {
                $user = $this->getUser();
                $params = $this->extractRequestParams();
 
-               if ( is_null( $params['text'] ) && is_null( $params['appendtext'] ) &&
-                       is_null( $params['prependtext'] ) &&
-                       $params['undo'] == 0
-               ) {
-                       $this->dieUsageMsg( 'missingtext' );
-               }
+               $this->requireAtLeastOneParameter( $params, 'text', 'appendtext', 'prependtext', 'undo' );
 
                $pageObj = $this->getTitleOrPageId( $params );
                $titleObj = $pageObj->getTitle();
@@ -55,9 +50,7 @@ class ApiEditPage extends ApiBase {
                        if ( $params['prependtext'] === null && $params['appendtext'] === null
                                && $params['section'] !== 'new'
                        ) {
-                               $this->dieUsage( 'You have attempted to edit using the "redirect"-following'
-                                       . ' mode, which must be used in conjuction with section=new, prependtext'
-                                       . ', or appendtext.', 'redirect-appendonly' );
+                               $this->dieWithError( 'apierror-redirect-appendonly' );
                        }
                        if ( $titleObj->isRedirect() ) {
                                $oldTitle = $titleObj;
@@ -105,10 +98,7 @@ class ApiEditPage extends ApiBase {
                if ( $params['undo'] > 0 ) {
                        // allow undo via api
                } elseif ( $contentHandler->supportsDirectApiEditing() === false ) {
-                       $this->dieUsage(
-                               "Direct editing via API is not supported for content model $model used by $name",
-                               'no-direct-editing'
-                       );
+                       $this->dieWithError( [ 'apierror-no-direct-editing', $model, $name ] );
                }
 
                if ( !isset( $params['contentformat'] ) || $params['contentformat'] == '' ) {
@@ -118,49 +108,21 @@ class ApiEditPage extends ApiBase {
                }
 
                if ( !$contentHandler->isSupportedFormat( $contentFormat ) ) {
-
-                       $this->dieUsage( "The requested format $contentFormat is not supported for content model " .
-                               " $model used by $name", 'badformat' );
+                       $this->dieWithError( [ 'apierror-badformat', $contentFormat, $model, $name ] );
                }
 
                if ( $params['createonly'] && $titleObj->exists() ) {
-                       $this->dieUsageMsg( 'createonly-exists' );
+                       $this->dieWithError( 'apierror-articleexists' );
                }
                if ( $params['nocreate'] && !$titleObj->exists() ) {
-                       $this->dieUsageMsg( 'nocreate-missing' );
+                       $this->dieWithError( 'apierror-missingtitle' );
                }
 
                // Now let's check whether we're even allowed to do this
-               $errors = $titleObj->getUserPermissionsErrors( 'edit', $user );
-               if ( !$titleObj->exists() ) {
-                       $errors = array_merge( $errors, $titleObj->getUserPermissionsErrors( 'create', $user ) );
-               }
-               if ( count( $errors ) ) {
-                       if ( is_array( $errors[0] ) ) {
-                               switch ( $errors[0][0] ) {
-                                       case 'blockedtext':
-                                               $this->dieUsage(
-                                                       'You have been blocked from editing',
-                                                       'blocked',
-                                                       0,
-                                                       [ 'blockinfo' => ApiQueryUserInfo::getBlockInfo( $user->getBlock() ) ]
-                                               );
-                                               break;
-                                       case 'autoblockedtext':
-                                               $this->dieUsage(
-                                                       'Your IP address has been blocked automatically, because it was used by a blocked user',
-                                                       'autoblocked',
-                                                       0,
-                                                       [ 'blockinfo' => ApiQueryUserInfo::getBlockInfo( $user->getBlock() ) ]
-                                               );
-                                               break;
-                                       default:
-                                               $this->dieUsageMsg( $errors[0] );
-                               }
-                       } else {
-                               $this->dieUsageMsg( $errors[0] );
-                       }
-               }
+               $this->checkTitleUserPermissions(
+                       $titleObj,
+                       $titleObj->exists() ? 'edit' : [ 'edit', 'create' ]
+               );
 
                $toMD5 = $params['text'];
                if ( !is_null( $params['appendtext'] ) || !is_null( $params['prependtext'] ) ) {
@@ -178,8 +140,11 @@ class ApiEditPage extends ApiBase {
                                        try {
                                                $content = ContentHandler::makeContent( $text, $this->getTitle() );
                                        } catch ( MWContentSerializationException $ex ) {
-                                               $this->dieUsage( $ex->getMessage(), 'parseerror' );
-
+                                               // @todo: Internationalize MWContentSerializationException
+                                               $this->dieWithError(
+                                                       [ 'apierror-contentserializationexception', wfEscapeWikiText( $ex->getMessage() ) ],
+                                                       'parseerror'
+                                               );
                                                return;
                                        }
                                } else {
@@ -191,17 +156,14 @@ class ApiEditPage extends ApiBase {
                        // @todo Add support for appending/prepending to the Content interface
 
                        if ( !( $content instanceof TextContent ) ) {
-                               $mode = $contentHandler->getModelID();
-                               $this->dieUsage( "Can't append to pages using content model $mode", 'appendnotsupported' );
+                               $modelName = $contentHandler->getModelID();
+                               $this->dieWithError( [ 'apierror-appendnotsupported', $modelName ] );
                        }
 
                        if ( !is_null( $params['section'] ) ) {
                                if ( !$contentHandler->supportsSections() ) {
                                        $modelName = $contentHandler->getModelID();
-                                       $this->dieUsage(
-                                               "Sections are not supported for this content model: $modelName.",
-                                               'sectionsnotsupported'
-                                       );
+                                       $this->dieWithError( [ 'apierror-sectionsnotsupported', $modelName ] );
                                }
 
                                if ( $params['section'] == 'new' ) {
@@ -213,7 +175,7 @@ class ApiEditPage extends ApiBase {
                                        $content = $content->getSection( $section );
 
                                        if ( !$content ) {
-                                               $this->dieUsage( "There is no section {$section}.", 'nosuchsection' );
+                                               $this->dieWithError( [ 'apierror-nosuchsection', wfEscapeWikiText( $section ) ] );
                                        }
                                }
                        }
@@ -238,22 +200,22 @@ class ApiEditPage extends ApiBase {
                        }
                        $undoRev = Revision::newFromId( $params['undo'] );
                        if ( is_null( $undoRev ) || $undoRev->isDeleted( Revision::DELETED_TEXT ) ) {
-                               $this->dieUsageMsg( [ 'nosuchrevid', $params['undo'] ] );
+                               $this->dieWithError( [ 'apierror-nosuchrevid', $params['undo'] ] );
                        }
 
                        if ( $params['undoafter'] == 0 ) {
                                $undoafterRev = $undoRev->getPrevious();
                        }
                        if ( is_null( $undoafterRev ) || $undoafterRev->isDeleted( Revision::DELETED_TEXT ) ) {
-                               $this->dieUsageMsg( [ 'nosuchrevid', $params['undoafter'] ] );
+                               $this->dieWithError( [ 'apierror-nosuchrevid', $params['undoafter'] ] );
                        }
 
                        if ( $undoRev->getPage() != $pageObj->getId() ) {
-                               $this->dieUsageMsg( [ 'revwrongpage', $undoRev->getId(),
+                               $this->dieWithError( [ 'apierror-revwrongpage', $undoRev->getId(),
                                        $titleObj->getPrefixedText() ] );
                        }
                        if ( $undoafterRev->getPage() != $pageObj->getId() ) {
-                               $this->dieUsageMsg( [ 'revwrongpage', $undoafterRev->getId(),
+                               $this->dieWithError( [ 'apierror-revwrongpage', $undoafterRev->getId(),
                                        $titleObj->getPrefixedText() ] );
                        }
 
@@ -264,7 +226,7 @@ class ApiEditPage extends ApiBase {
                        );
 
                        if ( !$newContent ) {
-                               $this->dieUsageMsg( 'undo-failure' );
+                               $this->dieWithError( 'undo-failure', 'undofailure' );
                        }
                        if ( empty( $params['contentmodel'] )
                                && empty( $params['contentformat'] )
@@ -293,7 +255,7 @@ class ApiEditPage extends ApiBase {
 
                // See if the MD5 hash checks out
                if ( !is_null( $params['md5'] ) && md5( $toMD5 ) !== $params['md5'] ) {
-                       $this->dieUsageMsg( 'hashcheckfailed' );
+                       $this->dieWithError( 'apierror-badmd5' );
                }
 
                // EditPage wants to parse its stuff from a WebRequest
@@ -347,14 +309,13 @@ class ApiEditPage extends ApiBase {
                if ( !is_null( $params['section'] ) ) {
                        $section = $params['section'];
                        if ( !preg_match( '/^((T-)?\d+|new)$/', $section ) ) {
-                               $this->dieUsage( "The section parameter must be a valid section id or 'new'",
-                                       'invalidsection' );
+                               $this->dieWithError( 'apierror-invalidsection' );
                        }
                        $content = $pageObj->getContent();
                        if ( $section !== '0' && $section != 'new'
                                && ( !$content || !$content->getSection( $section ) )
                        ) {
-                               $this->dieUsage( "There is no section {$section}.", 'nosuchsection' );
+                               $this->dieWithError( [ 'apierror-nosuchsection', $section ] );
                        }
                        $requestArray['wpSection'] = $params['section'];
                } else {
@@ -423,7 +384,7 @@ class ApiEditPage extends ApiBase {
                                return;
                        }
 
-                       $this->dieUsageMsg( 'hookaborted' );
+                       $this->dieWithError( 'hookaborted' );
                }
 
                // Do the actual save
@@ -445,67 +406,22 @@ class ApiEditPage extends ApiBase {
                                        $r['result'] = 'Failure';
                                        $apiResult->addValue( null, $this->getModuleName(), $r );
                                        return;
-                               } else {
-                                       $this->dieUsageMsg( 'hookaborted' );
                                }
-
-                       case EditPage::AS_PARSE_ERROR:
-                               $this->dieUsage( $status->getMessage(), 'parseerror' );
-
-                       case EditPage::AS_IMAGE_REDIRECT_ANON:
-                               $this->dieUsageMsg( 'noimageredirect-anon' );
-
-                       case EditPage::AS_IMAGE_REDIRECT_LOGGED:
-                               $this->dieUsageMsg( 'noimageredirect-logged' );
-
-                       case EditPage::AS_SPAM_ERROR:
-                               $this->dieUsageMsg( [ 'spamdetected', $result['spam'] ] );
+                               if ( !$status->getErrors() ) {
+                                       $status->fatal( 'hookaborted' );
+                               }
+                               $this->dieStatus( $status );
 
                        case EditPage::AS_BLOCKED_PAGE_FOR_USER:
-                               $this->dieUsage(
-                                       'You have been blocked from editing',
+                               $this->dieWithError(
+                                       'apierror-blocked',
                                        'blocked',
-                                       0,
                                        [ 'blockinfo' => ApiQueryUserInfo::getBlockInfo( $user->getBlock() ) ]
                                );
 
-                       case EditPage::AS_MAX_ARTICLE_SIZE_EXCEEDED:
-                       case EditPage::AS_CONTENT_TOO_BIG:
-                               $this->dieUsageMsg( [ 'contenttoobig', $this->getConfig()->get( 'MaxArticleSize' ) ] );
-
-                       case EditPage::AS_READ_ONLY_PAGE_ANON:
-                               $this->dieUsageMsg( 'noedit-anon' );
-
-                       case EditPage::AS_READ_ONLY_PAGE_LOGGED:
-                               $this->dieUsageMsg( 'noedit' );
-
                        case EditPage::AS_READ_ONLY_PAGE:
                                $this->dieReadOnly();
 
-                       case EditPage::AS_RATE_LIMITED:
-                               $this->dieUsageMsg( 'actionthrottledtext' );
-
-                       case EditPage::AS_ARTICLE_WAS_DELETED:
-                               $this->dieUsageMsg( 'wasdeleted' );
-
-                       case EditPage::AS_NO_CREATE_PERMISSION:
-                               $this->dieUsageMsg( 'nocreate-loggedin' );
-
-                       case EditPage::AS_NO_CHANGE_CONTENT_MODEL:
-                               $this->dieUsageMsg( 'cantchangecontentmodel' );
-
-                       case EditPage::AS_BLANK_ARTICLE:
-                               $this->dieUsageMsg( 'blankpage' );
-
-                       case EditPage::AS_CONFLICT_DETECTED:
-                               $this->dieUsageMsg( 'editconflict' );
-
-                       case EditPage::AS_TEXTBOX_EMPTY:
-                               $this->dieUsageMsg( 'emptynewsection' );
-
-                       case EditPage::AS_CHANGE_TAG_ERROR:
-                               $this->dieStatus( $status );
-
                        case EditPage::AS_SUCCESS_NEW_ARTICLE:
                                $r['new'] = true;
                                // fall-through
@@ -526,15 +442,39 @@ class ApiEditPage extends ApiBase {
                                }
                                break;
 
-                       case EditPage::AS_SUMMARY_NEEDED:
-                               // Shouldn't happen since we set wpIgnoreBlankSummary, but just in case
-                               $this->dieUsageMsg( 'summaryrequired' );
-
-                       case EditPage::AS_END:
                        default:
-                               // $status came from WikiPage::doEditContent()
-                               $errors = $status->getErrorsArray();
-                               $this->dieUsageMsg( $errors[0] ); // TODO: Add new errors to message map
+                               // EditPage sometimes only sets the status code without setting
+                               // any actual error messages. Supply defaults for those cases.
+                               $maxArticleSize = $this->getConfig()->get( 'MaxArticleSize' );
+                               $defaultMessages = [
+                                       // Currently needed
+                                       EditPage::AS_IMAGE_REDIRECT_ANON => [ 'apierror-noimageredirect-anon' ],
+                                       EditPage::AS_IMAGE_REDIRECT_LOGGED => [ 'apierror-noimageredirect-logged' ],
+                                       EditPage::AS_CONTENT_TOO_BIG => [ 'apierror-contenttoobig', $maxArticleSize ],
+                                       EditPage::AS_MAX_ARTICLE_SIZE_EXCEEDED => [ 'apierror-contenttoobig', $maxArticleSize ],
+                                       EditPage::AS_READ_ONLY_PAGE_ANON => [ 'apierror-noedit-anon' ],
+                                       EditPage::AS_NO_CHANGE_CONTENT_MODEL => [ 'apierror-cantchangecontentmodel' ],
+                                       EditPage::AS_ARTICLE_WAS_DELETED => [ 'apierror-pagedeleted' ],
+                                       EditPage::AS_CONFLICT_DETECTED => [ 'editconflict' ],
+
+                                       // Currently shouldn't be needed
+                                       EditPage::AS_SPAM_ERROR => [ 'apierror-spamdetected', wfEscapeWikiText( $result['spam'] ) ],
+                                       EditPage::AS_READ_ONLY_PAGE_LOGGED => [ 'apierror-noedit' ],
+                                       EditPage::AS_RATE_LIMITED => [ 'apierror-ratelimited' ],
+                                       EditPage::AS_NO_CREATE_PERMISSION => [ 'nocreate-loggedin' ],
+                                       EditPage::AS_BLANK_ARTICLE => [ 'apierror-emptypage' ],
+                                       EditPage::AS_TEXTBOX_EMPTY => [ 'apierror-emptynewsection' ],
+                                       EditPage::AS_SUMMARY_NEEDED => [ 'apierror-summaryrequired' ],
+                               ];
+                               if ( !$status->getErrors() ) {
+                                       if ( isset( $defaultMessages[$status->value] ) ) {
+                                               call_user_func_array( [ $status, 'fatal' ], $defaultMessages[$status->value] );
+                                       } else {
+                                               wfWarn( __METHOD__ . ": Unknown EditPage code {$status->value} with no message" );
+                                               $status->fatal( 'apierror-unknownerror-editpage', $status->value );
+                                       }
+                               }
+                               $this->dieStatus( $status );
                                break;
                }
                $apiResult->addValue( null, $this->getModuleName(), $r );
index 192378e..8aff6f8 100644 (file)
@@ -36,7 +36,16 @@ class ApiEmailUser extends ApiBase {
                // Validate target
                $targetUser = SpecialEmailUser::getTarget( $params['target'] );
                if ( !( $targetUser instanceof User ) ) {
-                       $this->dieUsageMsg( [ $targetUser ] );
+                       switch ( $targetUser ) {
+                               case 'notarget':
+                                       $this->dieWithError( 'apierror-notarget' );
+                               case 'noemail':
+                                       $this->dieWithError( [ 'noemail', $params['target'] ] );
+                               case 'nowikiemail':
+                                       $this->dieWithError( 'nowikiemailtext', 'nowikiemail' );
+                               default:
+                                       $this->dieWithError( [ 'apierror-unknownerror', $targetUser ] );
+                       }
                }
 
                // Check permissions and errors
@@ -46,7 +55,7 @@ class ApiEmailUser extends ApiBase {
                        $this->getConfig()
                );
                if ( $error ) {
-                       $this->dieUsageMsg( [ $error ] );
+                       $this->dieWithError( $error );
                }
 
                $data = [
@@ -56,25 +65,16 @@ class ApiEmailUser extends ApiBase {
                        'CCMe' => $params['ccme'],
                ];
                $retval = SpecialEmailUser::submit( $data, $this->getContext() );
-
-               if ( $retval instanceof Status ) {
-                       // SpecialEmailUser sometimes returns a status
-                       // sometimes it doesn't.
-                       if ( $retval->isGood() ) {
-                               $retval = true;
-                       } else {
-                               $retval = $retval->getErrorsArray();
-                       }
+               if ( !$retval instanceof Status ) {
+                       // This is probably the reason
+                       $retval = Status::newFatal( 'hookaborted' );
                }
 
-               if ( $retval === true ) {
-                       $result = [ 'result' => 'Success' ];
-               } else {
-                       $result = [
-                               'result' => 'Failure',
-                               'message' => $retval
-                       ];
-               }
+               $result = array_filter( [
+                       'result' => $retval->isGood() ? 'Success' : $retval->isOk() ? 'Warnings' : 'Failure',
+                       'warnings' => $this->getErrorFormatter()->arrayFromStatus( $retval, 'warning' ),
+                       'errors' => $this->getErrorFormatter()->arrayFromStatus( $retval, 'error' ),
+               ] );
 
                $this->getResult()->addValue( null, $this->getModuleName(), $result );
        }
index 6d9184f..4fb19b8 100644 (file)
@@ -43,7 +43,9 @@ class ApiErrorFormatter {
         * @param ApiResult $result Into which data will be added
         * @param Language $lang Used for i18n
         * @param string $format
-        *  - text: Error message as wikitext
+        *  - plaintext: Error message as something vaguely like plaintext
+        *    (it's basically wikitext with HTML tags stripped and entities decoded)
+        *  - wikitext: Error message as wikitext
         *  - html: Error message as HTML
         *  - raw: Raw message key and parameters, no human-readable text
         *  - none: Code and data only, no human-readable text
@@ -56,6 +58,15 @@ class ApiErrorFormatter {
                $this->format = $format;
        }
 
+       /**
+        * Fetch the Language for this formatter
+        * @since 1.29
+        * @return Language
+        */
+       public function getLanguage() {
+               return $this->lang;
+       }
+
        /**
         * Fetch a dummy title to set on Messages
         * @return Title
@@ -69,53 +80,49 @@ class ApiErrorFormatter {
 
        /**
         * Add a warning to the result
-        * @param string $moduleName
-        * @param MessageSpecifier|array|string $msg i18n message for the warning
-        * @param string $code Machine-readable code for the warning. Defaults as
-        *   for IApiMessage::getApiCode().
-        * @param array $data Machine-readable data for the warning, if any.
-        *   Uses IApiMessage::getApiData() if $msg implements that interface.
+        * @param string|null $modulePath
+        * @param Message|array|string $msg Warning message. See ApiMessage::create().
+        * @param string|null $code See ApiMessage::create().
+        * @param array|null $data See ApiMessage::create().
         */
-       public function addWarning( $moduleName, $msg, $code = null, $data = null ) {
+       public function addWarning( $modulePath, $msg, $code = null, $data = null ) {
                $msg = ApiMessage::create( $msg, $code, $data )
                        ->inLanguage( $this->lang )
                        ->title( $this->getDummyTitle() )
                        ->useDatabase( $this->useDB );
-               $this->addWarningOrError( 'warning', $moduleName, $msg );
+               $this->addWarningOrError( 'warning', $modulePath, $msg );
        }
 
        /**
         * Add an error to the result
-        * @param string $moduleName
-        * @param MessageSpecifier|array|string $msg i18n message for the error
-        * @param string $code Machine-readable code for the warning. Defaults as
-        *   for IApiMessage::getApiCode().
-        * @param array $data Machine-readable data for the warning, if any.
-        *   Uses IApiMessage::getApiData() if $msg implements that interface.
+        * @param string|null $modulePath
+        * @param Message|array|string $msg Warning message. See ApiMessage::create().
+        * @param string|null $code See ApiMessage::create().
+        * @param array|null $data See ApiMessage::create().
         */
-       public function addError( $moduleName, $msg, $code = null, $data = null ) {
+       public function addError( $modulePath, $msg, $code = null, $data = null ) {
                $msg = ApiMessage::create( $msg, $code, $data )
                        ->inLanguage( $this->lang )
                        ->title( $this->getDummyTitle() )
                        ->useDatabase( $this->useDB );
-               $this->addWarningOrError( 'error', $moduleName, $msg );
+               $this->addWarningOrError( 'error', $modulePath, $msg );
        }
 
        /**
-        * Add warnings and errors from a Status object to the result
-        * @param string $moduleName
-        * @param Status $status
+        * Add warnings and errors from a StatusValue object to the result
+        * @param string|null $modulePath
+        * @param StatusValue $status
         * @param string[] $types 'warning' and/or 'error'
         */
        public function addMessagesFromStatus(
-               $moduleName, Status $status, $types = [ 'warning', 'error' ]
+               $modulePath, StatusValue $status, $types = [ 'warning', 'error' ]
        ) {
-               if ( $status->isGood() || !$status->errors ) {
+               if ( $status->isGood() || !$status->getErrors() ) {
                        return;
                }
 
                $types = (array)$types;
-               foreach ( $status->errors as $error ) {
+               foreach ( $status->getErrors() as $error ) {
                        if ( !in_array( $error['type'], $types, true ) ) {
                                continue;
                        }
@@ -127,40 +134,37 @@ class ApiErrorFormatter {
                                $tag = 'warning';
                        }
 
-                       if ( is_array( $error ) && isset( $error['message'] ) ) {
-                               // Normal case
-                               if ( $error['message'] instanceof Message ) {
-                                       $msg = ApiMessage::create( $error['message'], null, [] );
-                               } else {
-                                       $args = isset( $error['params'] ) ? $error['params'] : [];
-                                       array_unshift( $args, $error['message'] );
-                                       $error += [ 'params' => [] ];
-                                       $msg = ApiMessage::create( $args, null, [] );
-                               }
-                       } elseif ( is_array( $error ) ) {
-                               // Weird case handled by Message::getErrorMessage
-                               $msg = ApiMessage::create( $error, null, [] );
-                       } else {
-                               // Another weird case handled by Message::getErrorMessage
-                               $msg = ApiMessage::create( $error, null, [] );
-                       }
-
-                       $msg->inLanguage( $this->lang )
+                       $msg = ApiMessage::create( $error )
+                               ->inLanguage( $this->lang )
                                ->title( $this->getDummyTitle() )
                                ->useDatabase( $this->useDB );
-                       $this->addWarningOrError( $tag, $moduleName, $msg );
+                       $this->addWarningOrError( $tag, $modulePath, $msg );
                }
        }
 
        /**
-        * Format messages from a Status as an array
-        * @param Status $status
+        * Format a message as an array
+        * @param Message|array|string $msg Message. See ApiMessage::create().
+        * @param string|null $format
+        * @return array
+        */
+       public function formatMessage( $msg, $format = null ) {
+               $msg = ApiMessage::create( $msg )
+                       ->inLanguage( $this->lang )
+                       ->title( $this->getDummyTitle() )
+                       ->useDatabase( $this->useDB );
+               return $this->formatMessageInternal( $msg, $format ?: $this->format );
+       }
+
+       /**
+        * Format messages from a StatusValue as an array
+        * @param StatusValue $status
         * @param string $type 'warning' or 'error'
         * @param string|null $format
         * @return array
         */
-       public function arrayFromStatus( Status $status, $type = 'error', $format = null ) {
-               if ( $status->isGood() || !$status->errors ) {
+       public function arrayFromStatus( StatusValue $status, $type = 'error', $format = null ) {
+               if ( $status->isGood() || !$status->getErrors() ) {
                        return [];
                }
 
@@ -168,24 +172,69 @@ class ApiErrorFormatter {
                $formatter = new ApiErrorFormatter(
                        $result, $this->lang, $format ?: $this->format, $this->useDB
                );
-               $formatter->addMessagesFromStatus( 'dummy', $status, [ $type ] );
+               $formatter->addMessagesFromStatus( null, $status, [ $type ] );
                switch ( $type ) {
                        case 'error':
-                               return (array)$result->getResultData( [ 'errors', 'dummy' ] );
+                               return (array)$result->getResultData( [ 'errors' ] );
                        case 'warning':
-                               return (array)$result->getResultData( [ 'warnings', 'dummy' ] );
+                               return (array)$result->getResultData( [ 'warnings' ] );
                }
        }
 
        /**
-        * Actually add the warning or error to the result
-        * @param string $tag 'warning' or 'error'
-        * @param string $moduleName
+        * Turn wikitext into something resembling plaintext
+        * @since 1.29
+        * @param string $text
+        * @return string
+        */
+       public static function stripMarkup( $text ) {
+               // Turn semantic quoting tags to quotes
+               $ret = preg_replace( '!</?(var|kbd|samp|code)>!', '"', $text );
+
+               // Strip tags and decode.
+               $ret = html_entity_decode( strip_tags( $ret ), ENT_QUOTES | ENT_HTML5 );
+
+               return $ret;
+       }
+
+       /**
+        * Format a Message object for raw format
+        * @param MessageSpecifier $msg
+        * @return array
+        */
+       private function formatRawMessage( MessageSpecifier $msg ) {
+               $ret = [
+                       'key' => $msg->getKey(),
+                       'params' => $msg->getParams(),
+               ];
+               ApiResult::setIndexedTagName( $ret['params'], 'param' );
+
+               // Transform Messages as parameters in the style of Message::fooParam().
+               foreach ( $ret['params'] as $i => $param ) {
+                       if ( $param instanceof MessageSpecifier ) {
+                               $ret['params'][$i] = [ 'message' => $this->formatRawMessage( $param ) ];
+                       }
+               }
+               return $ret;
+       }
+
+       /**
+        * Format a message as an array
+        * @since 1.29
         * @param ApiMessage|ApiRawMessage $msg
+        * @param string|null $format
+        * @return array
         */
-       protected function addWarningOrError( $tag, $moduleName, $msg ) {
+       protected function formatMessageInternal( $msg, $format ) {
                $value = [ 'code' => $msg->getApiCode() ];
-               switch ( $this->format ) {
+               switch ( $format ) {
+                       case 'plaintext':
+                               $value += [
+                                       'text' => self::stripMarkup( $msg->text() ),
+                                       ApiResult::META_CONTENT => 'text',
+                               ];
+                               break;
+
                        case 'wikitext':
                                $value += [
                                        'text' => $msg->text(),
@@ -201,19 +250,34 @@ class ApiErrorFormatter {
                                break;
 
                        case 'raw':
-                               $value += [
-                                       'key' => $msg->getKey(),
-                                       'params' => $msg->getParams(),
-                               ];
-                               ApiResult::setIndexedTagName( $value['params'], 'param' );
+                               $value += $this->formatRawMessage( $msg );
                                break;
 
                        case 'none':
                                break;
                }
-               $value += $msg->getApiData();
+               $data = $msg->getApiData();
+               if ( $data ) {
+                       $value['data'] = $msg->getApiData() + [
+                               ApiResult::META_TYPE => 'assoc',
+                       ];
+               }
+               return $value;
+       }
 
-               $path = [ $tag . 's', $moduleName ];
+       /**
+        * Actually add the warning or error to the result
+        * @param string $tag 'warning' or 'error'
+        * @param string|null $modulePath
+        * @param ApiMessage|ApiRawMessage $msg
+        */
+       protected function addWarningOrError( $tag, $modulePath, $msg ) {
+               $value = $this->formatMessageInternal( $msg, $this->format );
+               if ( $modulePath !== null ) {
+                       $value += [ 'module' => $modulePath ];
+               }
+
+               $path = [ $tag . 's' ];
                $existing = $this->result->getResultData( $path );
                if ( $existing === null || !in_array( $value, $existing ) ) {
                        $flags = ApiResult::NO_SIZE_CHECK;
@@ -243,19 +307,19 @@ class ApiErrorFormatter_BackCompat extends ApiErrorFormatter {
                parent::__construct( $result, Language::factory( 'en' ), 'none', false );
        }
 
-       public function arrayFromStatus( Status $status, $type = 'error', $format = null ) {
-               if ( $status->isGood() || !$status->errors ) {
+       public function arrayFromStatus( StatusValue $status, $type = 'error', $format = null ) {
+               if ( $status->isGood() || !$status->getErrors() ) {
                        return [];
                }
 
                $result = [];
                foreach ( $status->getErrorsByType( $type ) as $error ) {
-                       if ( $error['message'] instanceof Message ) {
-                               $error = [
-                                       'message' => $error['message']->getKey(),
-                                       'params' => $error['message']->getParams(),
-                               ] + $error;
-                       }
+                       $msg = ApiMessage::create( $error );
+                       $error = [
+                               'message' => $msg->getKey(),
+                               'params' => $msg->getParams(),
+                               'code' => $msg->getApiCode(),
+                       ] + $error;
                        ApiResult::setIndexedTagName( $error['params'], 'param' );
                        $result[] = $error;
                }
@@ -264,24 +328,32 @@ class ApiErrorFormatter_BackCompat extends ApiErrorFormatter {
                return $result;
        }
 
-       protected function addWarningOrError( $tag, $moduleName, $msg ) {
-               $value = $msg->plain();
+       protected function formatMessageInternal( $msg, $format ) {
+               return [
+                       'code' => $msg->getApiCode(),
+                       'info' => $msg->text(),
+               ] + $msg->getApiData();
+       }
+
+       protected function addWarningOrError( $tag, $modulePath, $msg ) {
+               $value = self::stripMarkup( $msg->text() );
 
                if ( $tag === 'error' ) {
                        // In BC mode, only one error
-                       $code = $msg->getApiCode();
-                       if ( isset( ApiBase::$messageMap[$code] ) ) {
-                               // Backwards compatibility
-                               $code = ApiBase::$messageMap[$code]['code'];
-                       }
-
                        $value = [
-                               'code' => $code,
+                               'code' => $msg->getApiCode(),
                                'info' => $value,
                        ] + $msg->getApiData();
                        $this->result->addValue( null, 'error', $value,
                                ApiResult::OVERRIDE | ApiResult::ADD_ON_TOP | ApiResult::NO_SIZE_CHECK );
                } else {
+                       if ( $modulePath === null ) {
+                               $moduleName = 'unknown';
+                       } else {
+                               $i = strrpos( $modulePath, '+' );
+                               $moduleName = $i === false ? $modulePath : substr( $modulePath, $i + 1 );
+                       }
+
                        // Don't add duplicate warnings
                        $tag .= 's';
                        $path = [ $tag, $moduleName ];
index 10fb182..6f7cf65 100644 (file)
@@ -42,11 +42,9 @@ class ApiExpandTemplates extends ApiBase {
                $this->requireMaxOneParameter( $params, 'prop', 'generatexml' );
 
                if ( $params['prop'] === null ) {
-                       $this->logFeatureUsage( 'action=expandtemplates&!prop' );
-                       $this->setWarning( 'Because no values have been specified for the prop parameter, a ' .
-                               'legacy format has been used for the output. This format is deprecated, and in ' .
-                               'the future, a default value will be set for the prop parameter, causing the new' .
-                               'format to always be used.' );
+                       $this->addDeprecation(
+                               'apiwarn-deprecation-expandtemplates-prop', 'action=expandtemplates&!prop'
+                       );
                        $prop = [];
                } else {
                        $prop = array_flip( $params['prop'] );
@@ -57,13 +55,13 @@ class ApiExpandTemplates extends ApiBase {
                if ( $revid !== null ) {
                        $rev = Revision::newFromId( $revid );
                        if ( !$rev ) {
-                               $this->dieUsage( "There is no revision ID $revid", 'missingrev' );
+                               $this->dieWithError( [ 'apierror-nosuchrevid', $revid ] );
                        }
                        $title_obj = $rev->getTitle();
                } else {
                        $title_obj = Title::newFromText( $params['title'] );
                        if ( !$title_obj || $title_obj->isExternal() ) {
-                               $this->dieUsageMsg( [ 'invalidtitle', $params['title'] ] );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $params['title'] ) ] );
                        }
                }
 
@@ -161,9 +159,7 @@ class ApiExpandTemplates extends ApiBase {
                                }
                                if ( isset( $prop['modules'] ) &&
                                        !isset( $prop['jsconfigvars'] ) && !isset( $prop['encodedjsconfigvars'] ) ) {
-                                       $this->setWarning( "Property 'modules' was set but not 'jsconfigvars' " .
-                                               "or 'encodedjsconfigvars'. Configuration variables are necessary " .
-                                               'for proper module usage.' );
+                                       $this->addWarning( 'apiwarn-moduleswithoutvars' );
                                }
                        }
                }
index c7dc303..97720c6 100644 (file)
@@ -43,16 +43,16 @@ class ApiFeedContributions extends ApiBase {
 
                $config = $this->getConfig();
                if ( !$config->get( 'Feed' ) ) {
-                       $this->dieUsage( 'Syndication feeds are not available', 'feed-unavailable' );
+                       $this->dieWithError( 'feed-unavailable' );
                }
 
                $feedClasses = $config->get( 'FeedClasses' );
                if ( !isset( $feedClasses[$params['feedformat']] ) ) {
-                       $this->dieUsage( 'Invalid subscription feed type', 'feed-invalid' );
+                       $this->dieWithError( 'feed-invalid' );
                }
 
                if ( $params['showsizediff'] && $this->getConfig()->get( 'MiserMode' ) ) {
-                       $this->dieUsage( 'Size difference is disabled in Miser Mode', 'sizediffdisabled' );
+                       $this->dieWithError( 'apierror-sizediffdisabled' );
                }
 
                $msg = wfMessage( 'Contributions' )->inContentLanguage()->text();
index 813ac01..e0e50ed 100644 (file)
@@ -47,12 +47,12 @@ class ApiFeedRecentChanges extends ApiBase {
                $this->params = $this->extractRequestParams();
 
                if ( !$config->get( 'Feed' ) ) {
-                       $this->dieUsage( 'Syndication feeds are not available', 'feed-unavailable' );
+                       $this->dieWithError( 'feed-unavailable' );
                }
 
                $feedClasses = $config->get( 'FeedClasses' );
                if ( !isset( $feedClasses[$this->params['feedformat']] ) ) {
-                       $this->dieUsage( 'Invalid subscription feed type', 'feed-invalid' );
+                       $this->dieWithError( 'feed-invalid' );
                }
 
                $this->getMain()->setCacheMode( 'public' );
@@ -98,7 +98,7 @@ class ApiFeedRecentChanges extends ApiBase {
                if ( $specialClass === 'SpecialRecentchangeslinked' ) {
                        $title = Title::newFromText( $this->params['target'] );
                        if ( !$title ) {
-                               $this->dieUsageMsg( [ 'invalidtitle', $this->params['target'] ] );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $this->params['target'] ) ] );
                        }
 
                        $feed = new ChangesFeed( $feedFormat, false );
index af5b1af..b9bb761 100644 (file)
@@ -56,11 +56,11 @@ class ApiFeedWatchlist extends ApiBase {
                        $params = $this->extractRequestParams();
 
                        if ( !$config->get( 'Feed' ) ) {
-                               $this->dieUsage( 'Syndication feeds are not available', 'feed-unavailable' );
+                               $this->dieWithError( 'feed-unavailable' );
                        }
 
                        if ( !isset( $feedClasses[$params['feedformat']] ) ) {
-                               $this->dieUsage( 'Invalid subscription feed type', 'feed-invalid' );
+                               $this->dieWithError( 'feed-invalid' );
                        }
 
                        // limit to the number of hours going from now back
@@ -151,15 +151,26 @@ class ApiFeedWatchlist extends ApiBase {
                        $msg = wfMessage( 'watchlist' )->inContentLanguage()->escaped();
                        $feed = new $feedClasses[$feedFormat] ( $feedTitle, $msg, $feedUrl );
 
-                       if ( $e instanceof UsageException ) {
-                               $errorCode = $e->getCodeString();
+                       if ( $e instanceof ApiUsageException ) {
+                               foreach ( $e->getStatusValue()->getErrors() as $error ) {
+                                       $msg = ApiMessage::create( $error )
+                                               ->inLanguage( $this->getLanguage() );
+                                       $errorTitle = $this->msg( 'api-feed-error-title', $msg->getApiCode() );
+                                       $errorText = $msg->text();
+                                       $feedItems[] = new FeedItem( $errorTitle, $errorText, '', '', '' );
+                               }
                        } else {
-                               // Something is seriously wrong
-                               $errorCode = 'internal_api_error';
+                               if ( $e instanceof UsageException ) {
+                                       $errorCode = $e->getCodeString();
+                               } else {
+                                       // Something is seriously wrong
+                                       $errorCode = 'internal_api_error';
+                               }
+                               $errorTitle = $this->msg( 'api-feed-error-title', $msg->getApiCode() );
+                               $errorText = $e->getMessage();
+                               $feedItems[] = new FeedItem( $errorTitle, $errorText, '', '', '' );
                        }
 
-                       $errorText = $e->getMessage();
-                       $feedItems[] = new FeedItem( "Error ($errorCode)", $errorText, '', '', '' );
                        ApiFormatFeedWrapper::setResult( $this->getResult(), $feed, $feedItems );
                }
        }
index 97464d6..736898e 100644 (file)
@@ -45,7 +45,7 @@ class ApiFileRevert extends ApiBase {
                $this->validateParameters();
 
                // Check whether we're allowed to revert this file
-               $this->checkPermissions( $this->getUser() );
+               $this->checkTitleUserPermissions( $this->file->getTitle(), [ 'edit', 'upload' ] );
 
                $sourceUrl = $this->file->getArchiveVirtualUrl( $this->archiveName );
                $status = $this->file->upload(
@@ -70,23 +70,6 @@ class ApiFileRevert extends ApiBase {
                $this->getResult()->addValue( null, $this->getModuleName(), $result );
        }
 
-       /**
-        * Checks that the user has permissions to perform this revert.
-        * Dies with usage message on inadequate permissions.
-        * @param User $user The user to check.
-        */
-       protected function checkPermissions( $user ) {
-               $title = $this->file->getTitle();
-               $permissionErrors = array_merge(
-                       $title->getUserPermissionsErrors( 'edit', $user ),
-                       $title->getUserPermissionsErrors( 'upload', $user )
-               );
-
-               if ( $permissionErrors ) {
-                       $this->dieUsageMsg( $permissionErrors[0] );
-               }
-       }
-
        /**
         * Validate the user parameters and set $this->archiveName and $this->file.
         * Throws an error if validation fails
@@ -95,21 +78,23 @@ class ApiFileRevert extends ApiBase {
                // Validate the input title
                $title = Title::makeTitleSafe( NS_FILE, $this->params['filename'] );
                if ( is_null( $title ) ) {
-                       $this->dieUsageMsg( [ 'invalidtitle', $this->params['filename'] ] );
+                       $this->dieWithError(
+                               [ 'apierror-invalidtitle', wfEscapeWikiText( $this->params['filename'] ) ]
+                       );
                }
                $localRepo = RepoGroup::singleton()->getLocalRepo();
 
                // Check if the file really exists
                $this->file = $localRepo->newFile( $title );
                if ( !$this->file->exists() ) {
-                       $this->dieUsageMsg( 'notanarticle' );
+                       $this->dieWithError( 'apierror-missingtitle' );
                }
 
                // Check if the archivename is valid for this file
                $this->archiveName = $this->params['archivename'];
                $oldFile = $localRepo->newFromArchiveName( $title, $this->archiveName );
                if ( !$oldFile->exists() ) {
-                       $this->dieUsageMsg( 'filerevert-badversion' );
+                       $this->dieWithError( 'filerevert-badversion' );
                }
        }
 
index 2e917e1..8ebfe48 100644 (file)
@@ -84,8 +84,8 @@ class ApiFormatJson extends ApiFormatBase {
                                        break;
 
                                default:
-                                       $this->dieUsage( __METHOD__ .
-                                               ': Unknown value for \'formatversion\'', 'unknownformatversion' );
+                                       // Should have been caught during parameter validation
+                                       $this->dieDebug( __METHOD__, 'Unknown value for \'formatversion\'' );
                        }
                }
                $data = $this->getResult()->getResultData( null, $transform );
index fc25f47..a744f57 100644 (file)
@@ -55,7 +55,8 @@ class ApiFormatPhp extends ApiFormatBase {
                                break;
 
                        default:
-                               $this->dieUsage( __METHOD__ . ': Unknown value for \'formatversion\'', 'unknownformatversion' );
+                               // Should have been caught during parameter validation
+                               $this->dieDebug( __METHOD__, 'Unknown value for \'formatversion\'' );
                }
                $text = serialize( $this->getResult()->getResultData( null, $transforms ) );
 
@@ -67,11 +68,7 @@ class ApiFormatPhp extends ApiFormatBase {
                        in_array( 'wfOutputHandler', ob_list_handlers(), true ) &&
                        preg_match( '/\<\s*cross-domain-policy(?=\s|\>)/i', $text )
                ) {
-                       $this->dieUsage(
-                               'This response cannot be represented using format=php. ' .
-                               'See https://phabricator.wikimedia.org/T68776',
-                               'internalerror'
-                       );
+                       $this->dieWithError( 'apierror-formatphp', 'internalerror' );
                }
 
                $this->printText( $text );
index 9da040c..228b47e 100644 (file)
@@ -49,7 +49,7 @@ class ApiFormatRaw extends ApiFormatBase {
        public function getMimeType() {
                $data = $this->getResult()->getResultData();
 
-               if ( isset( $data['error'] ) ) {
+               if ( isset( $data['error'] ) || isset( $data['errors'] ) ) {
                        return $this->errorFallback->getMimeType();
                }
 
@@ -62,7 +62,7 @@ class ApiFormatRaw extends ApiFormatBase {
 
        public function initPrinter( $unused = false ) {
                $data = $this->getResult()->getResultData();
-               if ( isset( $data['error'] ) ) {
+               if ( isset( $data['error'] ) || isset( $data['errors'] ) ) {
                        $this->errorFallback->initPrinter( $unused );
                        if ( $this->mFailWithHTTPError ) {
                                $this->getMain()->getRequest()->response()->statusHeader( 400 );
@@ -74,7 +74,7 @@ class ApiFormatRaw extends ApiFormatBase {
 
        public function closePrinter() {
                $data = $this->getResult()->getResultData();
-               if ( isset( $data['error'] ) ) {
+               if ( isset( $data['error'] ) || isset( $data['errors'] ) ) {
                        $this->errorFallback->closePrinter();
                } else {
                        parent::closePrinter();
@@ -83,7 +83,7 @@ class ApiFormatRaw extends ApiFormatBase {
 
        public function execute() {
                $data = $this->getResult()->getResultData();
-               if ( isset( $data['error'] ) ) {
+               if ( isset( $data['error'] ) || isset( $data['errors'] ) ) {
                        $this->errorFallback->execute();
                        return;
                }
index a45dbeb..e4dfda0 100644 (file)
@@ -269,17 +269,17 @@ class ApiFormatXml extends ApiFormatBase {
        protected function addXslt() {
                $nt = Title::newFromText( $this->mXslt );
                if ( is_null( $nt ) || !$nt->exists() ) {
-                       $this->setWarning( 'Invalid or non-existent stylesheet specified' );
+                       $this->addWarning( 'apiwarn-invalidxmlstylesheet' );
 
                        return;
                }
                if ( $nt->getNamespace() != NS_MEDIAWIKI ) {
-                       $this->setWarning( 'Stylesheet should be in the MediaWiki namespace.' );
+                       $this->addWarning( 'apiwarn-invalidxmlstylesheetns' );
 
                        return;
                }
                if ( substr( $nt->getText(), -4 ) !== '.xsl' ) {
-                       $this->setWarning( 'Stylesheet should have .xsl extension.' );
+                       $this->addWarning( 'apiwarn-invalidxmlstylesheetext' );
 
                        return;
                }
index 37cb80a..72fb16d 100644 (file)
@@ -56,23 +56,29 @@ class ApiImageRotate extends ApiBase {
                        $file = wfFindFile( $title, [ 'latest' => true ] );
                        if ( !$file ) {
                                $r['result'] = 'Failure';
-                               $r['errormessage'] = 'File does not exist';
+                               $r['errors'] = $this->getErrorFormatter()->arrayFromStatus(
+                                       Status::newFatal( 'apierror-filedoesnotexist' )
+                               );
                                $result[] = $r;
                                continue;
                        }
                        $handler = $file->getHandler();
                        if ( !$handler || !$handler->canRotate() ) {
                                $r['result'] = 'Failure';
-                               $r['errormessage'] = 'File type cannot be rotated';
+                               $r['errors'] = $this->getErrorFormatter()->arrayFromStatus(
+                                       Status::newFatal( 'apierror-filetypecannotberotated' )
+                               );
                                $result[] = $r;
                                continue;
                        }
 
                        // Check whether we're allowed to rotate this file
-                       $permError = $this->checkPermissions( $this->getUser(), $file->getTitle() );
-                       if ( $permError !== null ) {
+                       $permError = $this->checkTitleUserPermissions( $file->getTitle(), [ 'edit', 'upload' ] );
+                       if ( $permError ) {
                                $r['result'] = 'Failure';
-                               $r['errormessage'] = $permError;
+                               $r['errors'] = $this->getErrorFormatter()->arrayFromStatus(
+                                       $this->errorArrayToStatus( $permError )
+                               );
                                $result[] = $r;
                                continue;
                        }
@@ -80,7 +86,9 @@ class ApiImageRotate extends ApiBase {
                        $srcPath = $file->getLocalRefPath();
                        if ( $srcPath === false ) {
                                $r['result'] = 'Failure';
-                               $r['errormessage'] = 'Cannot get local file path';
+                               $r['errors'] = $this->getErrorFormatter()->arrayFromStatus(
+                                       Status::newFatal( 'apierror-filenopath' )
+                               );
                                $result[] = $r;
                                continue;
                        }
@@ -102,11 +110,13 @@ class ApiImageRotate extends ApiBase {
                                        $r['result'] = 'Success';
                                } else {
                                        $r['result'] = 'Failure';
-                                       $r['errormessage'] = $this->getErrorFormatter()->arrayFromStatus( $status );
+                                       $r['errors'] = $this->getErrorFormatter()->arrayFromStatus( $status );
                                }
                        } else {
                                $r['result'] = 'Failure';
-                               $r['errormessage'] = $err->toText();
+                               $r['errors'] = $this->getErrorFormatter()->arrayFromStatus(
+                                       Status::newFatal( ApiMessage::create( $err->getMsg() ) )
+                               );
                        }
                        $result[] = $r;
                }
@@ -130,28 +140,6 @@ class ApiImageRotate extends ApiBase {
                return $this->mPageSet;
        }
 
-       /**
-        * Checks that the user has permissions to perform rotations.
-        * @param User $user The user to check
-        * @param Title $title
-        * @return string|null Permission error message, or null if there is no error
-        */
-       protected function checkPermissions( $user, $title ) {
-               $permissionErrors = array_merge(
-                       $title->getUserPermissionsErrors( 'edit', $user ),
-                       $title->getUserPermissionsErrors( 'upload', $user )
-               );
-
-               if ( $permissionErrors ) {
-                       // Just return the first error
-                       $msg = $this->parseMsg( $permissionErrors[0] );
-
-                       return $msg['info'];
-               }
-
-               return null;
-       }
-
        public function mustBePosted() {
                return true;
        }
index 10106ff..3f48f38 100644 (file)
@@ -42,10 +42,10 @@ class ApiImport extends ApiBase {
                $isUpload = false;
                if ( isset( $params['interwikisource'] ) ) {
                        if ( !$user->isAllowed( 'import' ) ) {
-                               $this->dieUsageMsg( 'cantimport' );
+                               $this->dieWithError( 'apierror-cantimport' );
                        }
                        if ( !isset( $params['interwikipage'] ) ) {
-                               $this->dieUsageMsg( [ 'missingparam', 'interwikipage' ] );
+                               $this->dieWithError( [ 'apierror-missingparam', 'interwikipage' ] );
                        }
                        $source = ImportStreamSource::newFromInterwiki(
                                $params['interwikisource'],
@@ -56,7 +56,7 @@ class ApiImport extends ApiBase {
                } else {
                        $isUpload = true;
                        if ( !$user->isAllowed( 'importupload' ) ) {
-                               $this->dieUsageMsg( 'cantimport-upload' );
+                               $this->dieWithError( 'apierror-cantimport-upload' );
                        }
                        $source = ImportStreamSource::newFromUpload( 'xml' );
                }
@@ -83,7 +83,7 @@ class ApiImport extends ApiBase {
                try {
                        $importer->doImport();
                } catch ( Exception $e ) {
-                       $this->dieUsageMsg( [ 'import-unknownerror', $e->getMessage() ] );
+                       $this->dieWithError( [ 'apierror-import-unknownerror', wfEscapeWikiText( $e->getMessage() ) ] );
                }
 
                $resultData = $reporter->getData();
index 1017607..9a21e76 100644 (file)
@@ -49,7 +49,7 @@ class ApiLinkAccount extends ApiBase {
 
        public function execute() {
                if ( !$this->getUser()->isLoggedIn() ) {
-                       $this->dieUsage( 'Must be logged in to link accounts', 'notloggedin' );
+                       $this->dieWithError( 'apierror-mustbeloggedin-linkaccounts', 'notloggedin' );
                }
 
                $params = $this->extractRequestParams();
@@ -60,8 +60,8 @@ class ApiLinkAccount extends ApiBase {
                        $bits = wfParseUrl( $params['returnurl'] );
                        if ( !$bits || $bits['scheme'] === '' ) {
                                $encParamName = $this->encodeParamName( 'returnurl' );
-                               $this->dieUsage(
-                                       "Invalid value '{$params['returnurl']}' for url parameter $encParamName",
+                               $this->dieWithError(
+                                       [ 'apierror-badurl', $encParamName, wfEscapeWikiText( $params['returnurl'] ) ],
                                        "badurl_{$encParamName}"
                                );
                        }
index 6ac261d..723dc33 100644 (file)
@@ -72,10 +72,11 @@ class ApiLogin extends ApiBase {
 
                try {
                        $this->requirePostedParameters( [ 'password', 'token' ] );
-               } catch ( UsageException $ex ) {
+               } catch ( ApiUsageException $ex ) {
                        // Make this a warning for now, upgrade to an error in 1.29.
-                       $this->setWarning( $ex->getMessage() );
-                       $this->logFeatureUsage( 'login-params-in-query-string' );
+                       foreach ( $ex->getStatusValue()->getErrors() as $error ) {
+                               $this->addDeprecation( $error, 'login-params-in-query-string' );
+                       }
                }
 
                $params = $this->extractRequestParams();
@@ -146,15 +147,10 @@ class ApiLogin extends ApiBase {
                        switch ( $res->status ) {
                                case AuthenticationResponse::PASS:
                                        if ( $this->getConfig()->get( 'EnableBotPasswords' ) ) {
-                                               $warn = 'Main-account login via action=login is deprecated and may stop working ' .
-                                                       'without warning.';
-                                               $warn .= ' To continue login with action=login, see [[Special:BotPasswords]].';
-                                               $warn .= ' To safely continue using main-account login, see action=clientlogin.';
+                                               $this->addDeprecation( 'apiwarn-deprecation-login-botpw', 'main-account-login' );
                                        } else {
-                                               $warn = 'Login via action=login is deprecated and may stop working without warning.';
-                                               $warn .= ' To safely log in, see action=clientlogin.';
+                                               $this->addDeprecation( 'apiwarn-deprecation-login-nobotpw', 'main-account-login' );
                                        }
-                                       $this->setWarning( $warn );
                                        $authRes = 'Success';
                                        $loginType = 'AuthManager';
                                        break;
@@ -194,16 +190,16 @@ class ApiLogin extends ApiBase {
 
                        case 'NeedToken':
                                $result['token'] = $token->toString();
-                               $this->setWarning( 'Fetching a token via action=login is deprecated. ' .
-                                  'Use action=query&meta=tokens&type=login instead.' );
-                               $this->logFeatureUsage( 'action=login&!lgtoken' );
+                               $this->addDeprecation( 'apiwarn-deprecation-login-token', 'action=login&!lgtoken' );
                                break;
 
                        case 'WrongToken':
                                break;
 
                        case 'Failed':
-                               $result['reason'] = $message->useDatabase( 'false' )->inLanguage( 'en' )->text();
+                               $result['reason'] = ApiErrorFormatter::stripMarkup(
+                                       $message->useDatabase( false )->inLanguage( 'en' )->text()
+                               );
                                break;
 
                        case 'Aborted':
index 6a26e2e..d5c28f1 100644 (file)
@@ -45,9 +45,11 @@ class ApiLogout extends ApiBase {
 
                // Make sure it's possible to log out
                if ( !$session->canSetUser() ) {
-                       $this->dieUsage(
-                               'Cannot log out when using ' .
-                                       $session->getProvider()->describe( Language::factory( 'en' ) ),
+                       $this->dieWithError(
+                               [
+                                       'cannotlogoutnow-text',
+                                       $session->getProvider()->describe( $this->getErrorFormatter()->getLanguage() )
+                               ],
                                'cannotlogout'
                        );
                }
index 38299b4..fe6ed41 100644 (file)
@@ -46,6 +46,11 @@ class ApiMain extends ApiBase {
         */
        const API_DEFAULT_FORMAT = 'jsonfm';
 
+       /**
+        * When no uselang parameter is given, this language will be used
+        */
+       const API_DEFAULT_USELANG = 'user';
+
        /**
         * List of available modules: action name => module class
         */
@@ -140,7 +145,7 @@ class ApiMain extends ApiBase {
         */
        private $mPrinter;
 
-       private $mModuleMgr, $mResult, $mErrorFormatter;
+       private $mModuleMgr, $mResult, $mErrorFormatter = null;
        /** @var ApiContinuationManager|null */
        private $mContinuationManager;
        private $mAction;
@@ -229,7 +234,11 @@ class ApiMain extends ApiBase {
                        }
                }
 
-               $uselang = $this->getParameter( 'uselang' );
+               $this->mResult = new ApiResult( $this->getConfig()->get( 'APIMaxResultSize' ) );
+
+               // Setup uselang. This doesn't use $this->getParameter()
+               // because we're not ready to handle errors yet.
+               $uselang = $request->getVal( 'uselang', self::API_DEFAULT_USELANG );
                if ( $uselang === 'user' ) {
                        // Assume the parent context is going to return the user language
                        // for uselang=user (see T85635).
@@ -247,6 +256,29 @@ class ApiMain extends ApiBase {
                        }
                }
 
+               // Set up the error formatter. This doesn't use $this->getParameter()
+               // because we're not ready to handle errors yet.
+               $errorFormat = $request->getVal( 'errorformat', 'bc' );
+               $errorLangCode = $request->getVal( 'errorlang', 'uselang' );
+               $errorsUseDB = $request->getCheck( 'errorsuselocal' );
+               if ( in_array( $errorFormat, [ 'plaintext', 'wikitext', 'html', 'raw', 'none' ], true ) ) {
+                       if ( $errorLangCode === 'uselang' ) {
+                               $errorLang = $this->getLanguage();
+                       } elseif ( $errorLangCode === 'content' ) {
+                               global $wgContLang;
+                               $errorLang = $wgContLang;
+                       } else {
+                               $errorLangCode = RequestContext::sanitizeLangCode( $errorLangCode );
+                               $errorLang = Language::factory( $errorLangCode );
+                       }
+                       $this->mErrorFormatter = new ApiErrorFormatter(
+                               $this->mResult, $errorLang, $errorFormat, $errorsUseDB
+                       );
+               } else {
+                       $this->mErrorFormatter = new ApiErrorFormatter_BackCompat( $this->mResult );
+               }
+               $this->mResult->setErrorFormatter( $this->getErrorFormatter() );
+
                $this->mModuleMgr = new ApiModuleManager( $this );
                $this->mModuleMgr->addModules( self::$Modules, 'action' );
                $this->mModuleMgr->addModules( $config->get( 'APIModules' ), 'action' );
@@ -255,9 +287,6 @@ class ApiMain extends ApiBase {
 
                Hooks::run( 'ApiMain::moduleManager', [ $this->mModuleMgr ] );
 
-               $this->mResult = new ApiResult( $this->getConfig()->get( 'APIMaxResultSize' ) );
-               $this->mErrorFormatter = new ApiErrorFormatter_BackCompat( $this->mResult );
-               $this->mResult->setErrorFormatter( $this->mErrorFormatter );
                $this->mContinuationManager = null;
                $this->mEnableWrite = $enableWrite;
 
@@ -464,7 +493,9 @@ class ApiMain extends ApiBase {
        public function createPrinterByName( $format ) {
                $printer = $this->mModuleMgr->getModule( $format, 'format' );
                if ( $printer === null ) {
-                       $this->dieUsage( "Unrecognized format: {$format}", 'unknown_format' );
+                       $this->dieWithError(
+                               [ 'apierror-unknownformat', wfEscapeWikiText( $format ) ], 'unknown_format'
+                       );
                }
 
                return $printer;
@@ -542,7 +573,7 @@ class ApiMain extends ApiBase {
         */
        protected function handleException( Exception $e ) {
                // Bug 63145: Rollback any open database transactions
-               if ( !( $e instanceof UsageException ) ) {
+               if ( !( $e instanceof ApiUsageException || $e instanceof UsageException ) ) {
                        // UsageExceptions are intentional, so don't rollback if that's the case
                        try {
                                MWExceptionHandler::rollbackMasterChangesAndLog( $e );
@@ -557,7 +588,7 @@ class ApiMain extends ApiBase {
                Hooks::run( 'ApiMain::onException', [ $this, $e ] );
 
                // Log it
-               if ( !( $e instanceof UsageException ) ) {
+               if ( !( $e instanceof ApiUsageException || $e instanceof UsageException ) ) {
                        MWExceptionHandler::logException( $e );
                }
 
@@ -565,13 +596,13 @@ class ApiMain extends ApiBase {
                // If this fails, an unhandled exception should be thrown so that global error
                // handler will process and log it.
 
-               $errCode = $this->substituteResultWithError( $e );
+               $errCodes = $this->substituteResultWithError( $e );
 
                // Error results should not be cached
                $this->setCacheMode( 'private' );
 
                $response = $this->getRequest()->response();
-               $headerStr = 'MediaWiki-API-Error: ' . $errCode;
+               $headerStr = 'MediaWiki-API-Error: ' . join( ', ', $errCodes );
                $response->header( $headerStr );
 
                // Reset and print just the error message
@@ -580,14 +611,31 @@ class ApiMain extends ApiBase {
                // Printer may not be initialized if the extractRequestParams() fails for the main module
                $this->createErrorPrinter();
 
+               $failed = false;
                try {
                        $this->printResult( $e->getCode() );
+               } catch ( ApiUsageException $ex ) {
+                       // The error printer itself is failing. Try suppressing its request
+                       // parameters and redo.
+                       $failed = true;
+                       $this->addWarning( 'apiwarn-errorprinterfailed' );
+                       foreach ( $ex->getStatusValue()->getErrors() as $error ) {
+                               try {
+                                       $this->mPrinter->addWarning( $error );
+                               } catch ( Exception $ex2 ) {
+                                       // WTF?
+                                       $this->addWarning( $error );
+                               }
+                       }
                } catch ( UsageException $ex ) {
                        // The error printer itself is failing. Try suppressing its request
                        // parameters and redo.
-                       $this->setWarning(
-                               'Error printer failed (will retry without params): ' . $ex->getMessage()
+                       $failed = true;
+                       $this->addWarning(
+                               [ 'apiwarn-errorprinterfailed-ex', $ex->getMessage() ], 'errorprinterfailed'
                        );
+               }
+               if ( $failed ) {
                        $this->mPrinter = null;
                        $this->createErrorPrinter();
                        $this->mPrinter->forceDefaultParams();
@@ -958,99 +1006,145 @@ class ApiMain extends ApiBase {
        /**
         * Create an error message for the given exception.
         *
-        * If the exception is a UsageException then
-        * UsageException::getMessageArray() will be called to create the message.
+        * If an ApiUsageException, errors/warnings will be extracted from the
+        * embedded StatusValue.
+        *
+        * If a base UsageException, the getMessageArray() method will be used to
+        * extract the code and English message for a single error (no warnings).
+        *
+        * Any other exception will be returned with a generic code and wrapper
+        * text around the exception's (presumably English) message as a single
+        * error (no warnings).
         *
         * @param Exception $e
-        * @return array ['code' => 'some string', 'info' => 'some other string']
+        * @param string $type 'error' or 'warning'
+        * @return ApiMessage[]
         * @since 1.27
         */
-       protected function errorMessageFromException( $e ) {
-               if ( $e instanceof UsageException ) {
+       protected function errorMessagesFromException( $e, $type = 'error' ) {
+               $messages = [];
+               if ( $e instanceof ApiUsageException ) {
+                       foreach ( $e->getStatusValue()->getErrorsByType( $type ) as $error ) {
+                               $messages[] = ApiMessage::create( $error );
+                       }
+               } elseif ( $type !== 'error' ) {
+                       // None of the rest have any messages for non-error types
+               } elseif ( $e instanceof UsageException ) {
                        // User entered incorrect parameters - generate error response
-                       $errMessage = $e->getMessageArray();
+                       $data = $e->getMessageArray();
+                       $code = $data['code'];
+                       $info = $data['info'];
+                       unset( $data['code'], $data['info'] );
+                       $messages[] = new ApiRawMessage( [ '$1', $info ], $code, $data );
                } else {
-                       $config = $this->getConfig();
                        // Something is seriously wrong
+                       $config = $this->getConfig();
+                       $code = 'internal_api_error_' . get_class( $e );
                        if ( ( $e instanceof DBQueryError ) && !$config->get( 'ShowSQLErrors' ) ) {
-                               $info = 'Database query error';
+                               $params = [ 'apierror-databaseerror', WebRequest::getRequestId() ];
                        } else {
-                               $info = "Exception Caught: {$e->getMessage()}";
+                               $params = [
+                                       'apierror-exceptioncaught',
+                                       WebRequest::getRequestId(),
+                                       wfEscapeWikiText( $e->getMessage() )
+                               ];
                        }
-
-                       $errMessage = [
-                               'code' => 'internal_api_error_' . get_class( $e ),
-                               'info' => '[' . WebRequest::getRequestId() . '] ' . $info,
-                       ];
+                       $messages[] = ApiMessage::create( $params, $code );
                }
-               return $errMessage;
+               return $messages;
        }
 
        /**
         * Replace the result data with the information about an exception.
-        * Returns the error code
         * @param Exception $e
-        * @return string
+        * @return string[] Error codes
         */
        protected function substituteResultWithError( $e ) {
                $result = $this->getResult();
+               $formatter = $this->getErrorFormatter();
                $config = $this->getConfig();
+               $errorCodes = [];
 
-               $errMessage = $this->errorMessageFromException( $e );
-               if ( $e instanceof UsageException ) {
-                       // User entered incorrect parameters - generate error response
+               // Remember existing warnings and errors across the reset
+               $errors = $result->getResultData( [ 'errors' ] );
+               $warnings = $result->getResultData( [ 'warnings' ] );
+               $result->reset();
+               if ( $warnings !== null ) {
+                       $result->addValue( null, 'warnings', $warnings, ApiResult::NO_SIZE_CHECK );
+               }
+               if ( $errors !== null ) {
+                       $result->addValue( null, 'errors', $errors, ApiResult::NO_SIZE_CHECK );
+
+                       // Collect the copied error codes for the return value
+                       foreach ( $errors as $error ) {
+                               if ( isset( $error['code'] ) ) {
+                                       $errorCodes[$error['code']] = true;
+                               }
+                       }
+               }
+
+               // Add errors from the exception
+               $modulePath = $e instanceof ApiUsageException ? $e->getModulePath() : null;
+               foreach ( $this->errorMessagesFromException( $e, 'error' ) as $msg ) {
+                       $errorCodes[$msg->getApiCode()] = true;
+                       $formatter->addError( $modulePath, $msg );
+               }
+               foreach ( $this->errorMessagesFromException( $e, 'warning' ) as $msg ) {
+                       $formatter->addWarning( $modulePath, $msg );
+               }
+
+               // Add additional data. Path depends on whether we're in BC mode or not.
+               // Data depends on the type of exception.
+               if ( $formatter instanceof ApiErrorFormatter_BackCompat ) {
+                       $path = [ 'error' ];
+               } else {
+                       $path = null;
+               }
+               if ( $e instanceof ApiUsageException || $e instanceof UsageException ) {
                        $link = wfExpandUrl( wfScript( 'api' ) );
-                       ApiResult::setContentValue( $errMessage, 'docref', "See $link for API usage" );
+                       $result->addContentValue(
+                               $path,
+                               'docref',
+                               $this->msg( 'api-usage-docref', $link )->inLanguage( $formatter->getLanguage() )->text()
+                       );
                } else {
-                       // Something is seriously wrong
                        if ( $config->get( 'ShowExceptionDetails' ) ) {
-                               ApiResult::setContentValue(
-                                       $errMessage,
+                               $result->addContentValue(
+                                       $path,
                                        'trace',
-                                       MWExceptionHandler::getRedactedTraceAsString( $e )
+                                       $this->msg( 'api-exception-trace',
+                                               get_class( $e ),
+                                               $e->getFile(),
+                                               $e->getLine(),
+                                               MWExceptionHandler::getRedactedTraceAsString( $e )
+                                       )->inLanguage( $formatter->getLanguage() )->text()
                                );
                        }
                }
 
-               // Remember all the warnings to re-add them later
-               $warnings = $result->getResultData( [ 'warnings' ] );
+               // Add the id and such
+               $this->addRequestedFields( [ 'servedby' ] );
 
-               $result->reset();
-               // Re-add the id
-               $requestid = $this->getParameter( 'requestid' );
-               if ( !is_null( $requestid ) ) {
-                       $result->addValue( null, 'requestid', $requestid, ApiResult::NO_SIZE_CHECK );
-               }
-               if ( $config->get( 'ShowHostnames' ) ) {
-                       // servedby is especially useful when debugging errors
-                       $result->addValue( null, 'servedby', wfHostname(), ApiResult::NO_SIZE_CHECK );
-               }
-               if ( $warnings !== null ) {
-                       $result->addValue( null, 'warnings', $warnings, ApiResult::NO_SIZE_CHECK );
-               }
-
-               $result->addValue( null, 'error', $errMessage, ApiResult::NO_SIZE_CHECK );
-
-               return $errMessage['code'];
+               return array_keys( $errorCodes );
        }
 
        /**
-        * Set up for the execution.
-        * @return array
+        * Add requested fields to the result
+        * @param string[] $force Which fields to force even if not requested. Accepted values are:
+        *  - servedby
         */
-       protected function setupExecuteAction() {
-               // First add the id to the top element
+       protected function addRequestedFields( $force = [] ) {
                $result = $this->getResult();
+
                $requestid = $this->getParameter( 'requestid' );
-               if ( !is_null( $requestid ) ) {
-                       $result->addValue( null, 'requestid', $requestid );
+               if ( $requestid !== null ) {
+                       $result->addValue( null, 'requestid', $requestid, ApiResult::NO_SIZE_CHECK );
                }
 
-               if ( $this->getConfig()->get( 'ShowHostnames' ) ) {
-                       $servedby = $this->getParameter( 'servedby' );
-                       if ( $servedby ) {
-                               $result->addValue( null, 'servedby', wfHostname() );
-                       }
+               if ( $this->getConfig()->get( 'ShowHostnames' ) && (
+                       in_array( 'servedby', $force, true ) || $this->getParameter( 'servedby' )
+               ) ) {
+                       $result->addValue( null, 'servedby', wfHostname(), ApiResult::NO_SIZE_CHECK );
                }
 
                if ( $this->getParameter( 'curtimestamp' ) ) {
@@ -1058,13 +1152,23 @@ class ApiMain extends ApiBase {
                                ApiResult::NO_SIZE_CHECK );
                }
 
-               $params = $this->extractRequestParams();
+               if ( $this->getParameter( 'responselanginfo' ) ) {
+                       $result->addValue( null, 'uselang', $this->getLanguage()->getCode(),
+                               ApiResult::NO_SIZE_CHECK );
+                       $result->addValue( null, 'errorlang', $this->getErrorFormatter()->getLanguage()->getCode(),
+                               ApiResult::NO_SIZE_CHECK );
+               }
+       }
 
-               $this->mAction = $params['action'];
+       /**
+        * Set up for the execution.
+        * @return array
+        */
+       protected function setupExecuteAction() {
+               $this->addRequestedFields();
 
-               if ( !is_string( $this->mAction ) ) {
-                       $this->dieUsage( 'The API requires a valid action parameter', 'unknown_action' );
-               }
+               $params = $this->extractRequestParams();
+               $this->mAction = $params['action'];
 
                return $params;
        }
@@ -1073,13 +1177,15 @@ class ApiMain extends ApiBase {
         * Set up the module for response
         * @return ApiBase The module that will handle this action
         * @throws MWException
-        * @throws UsageException
+        * @throws ApiUsageException
         */
        protected function setupModule() {
                // Instantiate the module requested by the user
                $module = $this->mModuleMgr->getModule( $this->mAction, 'action' );
                if ( $module === null ) {
-                       $this->dieUsage( 'The API requires a valid action parameter', 'unknown_action' );
+                       $this->dieWithError(
+                               [ 'apierror-unknownaction', wfEscapeWikiText( $this->mAction ) ], 'unknown_action'
+                       );
                }
                $moduleParams = $module->extractRequestParams();
 
@@ -1098,13 +1204,13 @@ class ApiMain extends ApiBase {
                        }
 
                        if ( !isset( $moduleParams['token'] ) ) {
-                               $this->dieUsageMsg( [ 'missingparam', 'token' ] );
+                               $module->dieWithError( [ 'apierror-missingparam', 'token' ] );
                        }
 
                        $module->requirePostedParameters( [ 'token' ] );
 
                        if ( !$module->validateToken( $moduleParams['token'], $moduleParams ) ) {
-                               $this->dieUsageMsg( 'sessionfailure' );
+                               $module->dieWithError( 'apierror-badtoken' );
                        }
                }
 
@@ -1128,10 +1234,10 @@ class ApiMain extends ApiBase {
                                $response->header( 'X-Database-Lag: ' . intval( $lag ) );
 
                                if ( $this->getConfig()->get( 'ShowHostnames' ) ) {
-                                       $this->dieUsage( "Waiting for $host: $lag seconds lagged", 'maxlag' );
+                                       $this->dieWithError( [ 'apierror-maxlag', $lag, $host ] );
                                }
 
-                               $this->dieUsage( "Waiting for a database server: $lag seconds lagged", 'maxlag' );
+                               $this->dieWithError( [ 'apierror-maxlag-generic', $lag ], 'maxlag' );
                        }
                }
 
@@ -1262,19 +1368,16 @@ class ApiMain extends ApiBase {
                if ( $module->isReadMode() && !User::isEveryoneAllowed( 'read' ) &&
                        !$user->isAllowed( 'read' )
                ) {
-                       $this->dieUsageMsg( 'readrequired' );
+                       $this->dieWithError( 'apierror-readapidenied' );
                }
 
                if ( $module->isWriteMode() ) {
                        if ( !$this->mEnableWrite ) {
-                               $this->dieUsageMsg( 'writedisabled' );
+                               $this->dieWithError( 'apierror-noapiwrite' );
                        } elseif ( !$user->isAllowed( 'writeapi' ) ) {
-                               $this->dieUsageMsg( 'writerequired' );
+                               $this->dieWithError( 'apierror-writeapidenied' );
                        } elseif ( $this->getRequest()->getHeader( 'Promise-Non-Write-API-Action' ) ) {
-                               $this->dieUsage(
-                                       'Promise-Non-Write-API-Action HTTP header cannot be sent to write API modules',
-                                       'promised-nonwrite-api'
-                               );
+                               $this->dieWithError( 'apierror-promised-nonwrite-api' );
                        }
 
                        $this->checkReadOnly( $module );
@@ -1283,7 +1386,7 @@ class ApiMain extends ApiBase {
                // Allow extensions to stop execution for arbitrary reasons.
                $message = false;
                if ( !Hooks::run( 'ApiCheckCanExecute', [ $module, $user, &$message ] ) ) {
-                       $this->dieUsageMsg( $message );
+                       $this->dieWithError( $message );
                }
        }
 
@@ -1329,12 +1432,9 @@ class ApiMain extends ApiBase {
                                "Api request failed as read only because the following DBs are lagged: $laggedServers"
                        );
 
-                       $parsed = $this->parseMsg( [ 'readonlytext' ] );
-                       $this->dieUsage(
-                               $parsed['info'],
-                               $parsed['code'],
-                               /* http error */
-                               0,
+                       $this->dieWithError(
+                               'readonly_lag',
+                               'readonly',
                                [ 'readonlyreason' => "Waiting for $numLagged lagged database(s)" ]
                        );
                }
@@ -1350,12 +1450,12 @@ class ApiMain extends ApiBase {
                        switch ( $params['assert'] ) {
                                case 'user':
                                        if ( $user->isAnon() ) {
-                                               $this->dieUsage( 'Assertion that the user is logged in failed', 'assertuserfailed' );
+                                               $this->dieWithError( 'apierror-assertuserfailed' );
                                        }
                                        break;
                                case 'bot':
                                        if ( !$user->isAllowed( 'bot' ) ) {
-                                               $this->dieUsage( 'Assertion that the user has the bot right failed', 'assertbotfailed' );
+                                               $this->dieWithError( 'apierror-assertbotfailed' );
                                        }
                                        break;
                        }
@@ -1363,9 +1463,8 @@ class ApiMain extends ApiBase {
                if ( isset( $params['assertuser'] ) ) {
                        $assertUser = User::newFromName( $params['assertuser'], false );
                        if ( !$assertUser || !$this->getUser()->equals( $assertUser ) ) {
-                               $this->dieUsage(
-                                       'Assertion that the user is "' . $params['assertuser'] . '" failed',
-                                       'assertnameduserfailed'
+                               $this->dieWithError(
+                                       [ 'apierror-assertnameduserfailed', wfEscapeWikiText( $params['assertuser'] ) ]
                                );
                        }
                }
@@ -1381,7 +1480,7 @@ class ApiMain extends ApiBase {
                if ( !$request->wasPosted() && $module->mustBePosted() ) {
                        // Module requires POST. GET request might still be allowed
                        // if $wgDebugApi is true, otherwise fail.
-                       $this->dieUsageMsgOrDebug( [ 'mustbeposted', $this->mAction ] );
+                       $this->dieWithErrorOrDebug( [ 'apierror-mustbeposted', $this->mAction ] );
                }
 
                // See if custom printer is used
@@ -1396,8 +1495,7 @@ class ApiMain extends ApiBase {
                        ( $this->getUser()->isLoggedIn() &&
                                $this->getUser()->requiresHTTPS() )
                ) ) {
-                       $this->logFeatureUsage( 'https-expected' );
-                       $this->setWarning( 'HTTP used when HTTPS was expected' );
+                       $this->addDeprecation( 'apiwarn-deprecation-httpsexpected', 'https-expected' );
                }
        }
 
@@ -1481,7 +1579,9 @@ class ApiMain extends ApiBase {
                ];
 
                if ( $e ) {
-                       $logCtx['errorCodes'][] = $this->errorMessageFromException( $e )['code'];
+                       foreach ( $this->errorMessagesFromException( $e ) as $msg ) {
+                               $logCtx['errorCodes'][] = $msg->getApiCode();
+                       }
                }
 
                // Construct space separated message for 'api' log channel
@@ -1560,9 +1660,7 @@ class ApiMain extends ApiBase {
                        if ( $this->getRequest()->getArray( $name ) !== null ) {
                                // See bug 10262 for why we don't just implode( '|', ... ) the
                                // array.
-                               $this->setWarning(
-                                       "Parameter '$name' uses unsupported PHP array syntax"
-                               );
+                               $this->addWarning( [ 'apiwarn-unsupportedarray', $name ] );
                        }
                        $ret = $default;
                }
@@ -1602,8 +1700,7 @@ class ApiMain extends ApiBase {
 
                if ( !$this->mInternalMode ) {
                        // Printer has not yet executed; don't warn that its parameters are unused
-                       $printerParams = array_map(
-                               [ $this->mPrinter, 'encodeParamName' ],
+                       $printerParams = $this->mPrinter->encodeParamName(
                                array_keys( $this->mPrinter->getFinalParams() ?: [] )
                        );
                        $unusedParams = array_diff( $allParams, $paramsUsed, $printerParams );
@@ -1612,8 +1709,11 @@ class ApiMain extends ApiBase {
                }
 
                if ( count( $unusedParams ) ) {
-                       $s = count( $unusedParams ) > 1 ? 's' : '';
-                       $this->setWarning( "Unrecognized parameter$s: '" . implode( $unusedParams, "', '" ) . "'" );
+                       $this->addWarning( [
+                               'apierror-unrecognizedparams',
+                               Message::listParam( array_map( 'wfEscapeWikiText', $unusedParams ), 'comma' ),
+                               count( $unusedParams )
+                       ] );
                }
        }
 
@@ -1624,7 +1724,7 @@ class ApiMain extends ApiBase {
         */
        protected function printResult( $httpCode = 0 ) {
                if ( $this->getConfig()->get( 'DebugAPI' ) !== false ) {
-                       $this->setWarning( 'SECURITY WARNING: $wgDebugAPI is enabled' );
+                       $this->addWarning( 'apiwarn-wgDebugAPI' );
                }
 
                $printer = $this->mPrinter;
@@ -1678,9 +1778,20 @@ class ApiMain extends ApiBase {
                        'requestid' => null,
                        'servedby' => false,
                        'curtimestamp' => false,
+                       'responselanginfo' => false,
                        'origin' => null,
                        'uselang' => [
-                               ApiBase::PARAM_DFLT => 'user',
+                               ApiBase::PARAM_DFLT => self::API_DEFAULT_USELANG,
+                       ],
+                       'errorformat' => [
+                               ApiBase::PARAM_TYPE => [ 'plaintext', 'wikitext', 'html', 'raw', 'none', 'bc' ],
+                               ApiBase::PARAM_DFLT => 'bc',
+                       ],
+                       'errorlang' => [
+                               ApiBase::PARAM_DFLT => 'uselang',
+                       ],
+                       'errorsuselocal' => [
+                               ApiBase::PARAM_DFLT => false,
                        ],
                ];
        }
@@ -1732,7 +1843,7 @@ class ApiMain extends ApiBase {
                        $help['permissions'] .= Html::rawElement( 'dd', null,
                                $this->msg( 'api-help-permissions-granted-to' )
                                        ->numParams( count( $groups ) )
-                                       ->params( $this->getLanguage()->commaList( $groups ) )
+                                       ->params( Message::listParam( $groups ) )
                                        ->parse()
                        );
                }
@@ -1831,70 +1942,6 @@ class ApiMain extends ApiBase {
        }
 }
 
-/**
- * This exception will be thrown when dieUsage is called to stop module execution.
- *
- * @ingroup API
- */
-class UsageException extends MWException {
-
-       private $mCodestr;
-
-       /**
-        * @var null|array
-        */
-       private $mExtraData;
-
-       /**
-        * @param string $message
-        * @param string $codestr
-        * @param int $code
-        * @param array|null $extradata
-        */
-       public function __construct( $message, $codestr, $code = 0, $extradata = null ) {
-               parent::__construct( $message, $code );
-               $this->mCodestr = $codestr;
-               $this->mExtraData = $extradata;
-
-               // This should never happen, so throw an exception about it that will
-               // hopefully get logged with a backtrace (T138585)
-               if ( !is_string( $codestr ) || $codestr === '' ) {
-                       throw new InvalidArgumentException( 'Invalid $codestr, was ' .
-                               ( $codestr === '' ? 'empty string' : gettype( $codestr ) )
-                       );
-               }
-       }
-
-       /**
-        * @return string
-        */
-       public function getCodeString() {
-               return $this->mCodestr;
-       }
-
-       /**
-        * @return array
-        */
-       public function getMessageArray() {
-               $result = [
-                       'code' => $this->mCodestr,
-                       'info' => $this->getMessage()
-               ];
-               if ( is_array( $this->mExtraData ) ) {
-                       $result = array_merge( $result, $this->mExtraData );
-               }
-
-               return $result;
-       }
-
-       /**
-        * @return string
-        */
-       public function __toString() {
-               return "{$this->getCodeString()}: {$this->getMessage()}";
-       }
-}
-
 /**
  * For really cool vim folding this needs to be at the end:
  * vim: foldmarker=@{,@} foldmethod=marker
index 617db22..3299f73 100644 (file)
@@ -32,11 +32,9 @@ class ApiManageTags extends ApiBase {
                if ( $params['operation'] !== 'delete'
                        && !$this->getUser()->isAllowed( 'managechangetags' )
                ) {
-                       $this->dieUsage( "You don't have permission to manage change tags",
-                               'permissiondenied' );
+                       $this->dieWithError( 'tags-manage-no-permission', 'permissiondenied' );
                } elseif ( !$this->getUser()->isAllowed( 'deletechangetags' ) ) {
-                       $this->dieUsage( "You don't have permission to delete change tags",
-                               'permissiondenied' );
+                       $this->dieWithError( 'tags-delete-no-permission', 'permissiondenied' );
                }
 
                $result = $this->getResult();
index 276f1c0..357698e 100644 (file)
@@ -42,24 +42,24 @@ class ApiMergeHistory extends ApiBase {
                if ( isset( $params['from'] ) ) {
                        $fromTitle = Title::newFromText( $params['from'] );
                        if ( !$fromTitle || $fromTitle->isExternal() ) {
-                               $this->dieUsageMsg( [ 'invalidtitle', $params['from'] ] );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $params['from'] ) ] );
                        }
                } elseif ( isset( $params['fromid'] ) ) {
                        $fromTitle = Title::newFromID( $params['fromid'] );
                        if ( !$fromTitle ) {
-                               $this->dieUsageMsg( [ 'nosuchpageid', $params['fromid'] ] );
+                               $this->dieWithError( [ 'apierror-nosuchpageid', $params['fromid'] ] );
                        }
                }
 
                if ( isset( $params['to'] ) ) {
                        $toTitle = Title::newFromText( $params['to'] );
                        if ( !$toTitle || $toTitle->isExternal() ) {
-                               $this->dieUsageMsg( [ 'invalidtitle', $params['to'] ] );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $params['to'] ) ] );
                        }
                } elseif ( isset( $params['toid'] ) ) {
                        $toTitle = Title::newFromID( $params['toid'] );
                        if ( !$toTitle ) {
-                               $this->dieUsageMsg( [ 'nosuchpageid', $params['toid'] ] );
+                               $this->dieWithError( [ 'apierror-nosuchpageid', $params['toid'] ] );
                        }
                }
 
index ae66778..9d69a77 100644 (file)
@@ -36,9 +36,10 @@ interface IApiMessage extends MessageSpecifier {
        /**
         * Returns a machine-readable code for use by the API
         *
-        * The message key is often sufficient, but sometimes there are multiple
-        * messages used for what is really the same underlying condition (e.g.
-        * badaccess-groups and badaccess-group0)
+        * If no code was specifically set, the message key is used as the code
+        * after removing "apiwarn-" or "apierror-" prefixes and applying
+        * backwards-compatibility mappings.
+        *
         * @return string
         */
        public function getApiCode();
@@ -51,7 +52,7 @@ interface IApiMessage extends MessageSpecifier {
 
        /**
         * Sets the machine-readable code for use by the API
-        * @param string|null $code If null, the message key should be returned by self::getApiCode()
+        * @param string|null $code If null, uses the default (see self::getApiCode())
         * @param array|null $data If non-null, passed to self::setApiData()
         */
        public function setApiCode( $code, array $data = null );
@@ -69,14 +70,95 @@ interface IApiMessage extends MessageSpecifier {
  * @ingroup API
  */
 trait ApiMessageTrait {
+
+       /**
+        * Compatibility code mappings for various MW messages.
+        * @todo Ideally anything relying on this should be changed to use ApiMessage.
+        */
+       protected static $messageMap = [
+               'actionthrottledtext' => 'ratelimited',
+               'autoblockedtext' => 'autoblocked',
+               'badaccess-group0' => 'permissiondenied',
+               'badaccess-groups' => 'permissiondenied',
+               'badipaddress' => 'invalidip',
+               'blankpage' => 'emptypage',
+               'blockedtext' => 'blocked',
+               'cannotdelete' => 'cantdelete',
+               'cannotundelete' => 'cantundelete',
+               'cantmove-titleprotected' => 'protectedtitle',
+               'cantrollback' => 'onlyauthor',
+               'confirmedittext' => 'confirmemail',
+               'content-not-allowed-here' => 'contentnotallowedhere',
+               'deleteprotected' => 'cantedit',
+               'delete-toobig' => 'bigdelete',
+               'edit-conflict' => 'editconflict',
+               'imagenocrossnamespace' => 'nonfilenamespace',
+               'imagetypemismatch' => 'filetypemismatch',
+               'importbadinterwiki' => 'badinterwiki',
+               'importcantopen' => 'cantopenfile',
+               'import-noarticle' => 'badinterwiki',
+               'importnofile' => 'nofile',
+               'importuploaderrorpartial' => 'partialupload',
+               'importuploaderrorsize' => 'filetoobig',
+               'importuploaderrortemp' => 'notempdir',
+               'ipb_already_blocked' => 'alreadyblocked',
+               'ipb_blocked_as_range' => 'blockedasrange',
+               'ipb_cant_unblock' => 'cantunblock',
+               'ipb_expiry_invalid' => 'invalidexpiry',
+               'ip_range_invalid' => 'invalidrange',
+               'mailnologin' => 'cantsend',
+               'markedaspatrollederror-noautopatrol' => 'noautopatrol',
+               'movenologintext' => 'cantmove-anon',
+               'movenotallowed' => 'cantmove',
+               'movenotallowedfile' => 'cantmovefile',
+               'namespaceprotected' => 'protectednamespace',
+               'nocreate-loggedin' => 'cantcreate',
+               'nocreatetext' => 'cantcreate-anon',
+               'noname' => 'invaliduser',
+               'nosuchusershort' => 'nosuchuser',
+               'notanarticle' => 'missingtitle',
+               'nouserspecified' => 'invaliduser',
+               'ns-specialprotected' => 'unsupportednamespace',
+               'protect-cantedit' => 'cantedit',
+               'protectedinterface' => 'protectednamespace-interface',
+               'protectedpagetext' => 'protectedpage',
+               'range_block_disabled' => 'rangedisabled',
+               'rcpatroldisabled' => 'patroldisabled',
+               'readonlytext' => 'readonly',
+               'sessionfailure' => 'badtoken',
+               'titleprotected' => 'protectedtitle',
+               'undo-failure' => 'undofailure',
+               'userrights-nodatabase' => 'nosuchdatabase',
+               'userrights-no-interwiki' => 'nointerwikiuserrights',
+       ];
+
        protected $apiCode = null;
        protected $apiData = [];
 
        public function getApiCode() {
-               return $this->apiCode === null ? $this->getKey() : $this->apiCode;
+               if ( $this->apiCode === null ) {
+                       $key = $this->getKey();
+                       if ( isset( self::$messageMap[$key] ) ) {
+                               $this->apiCode = self::$messageMap[$key];
+                       } elseif ( $key === 'apierror-missingparam' ) {
+                               /// @todo: Kill this case along with ApiBase::$messageMap
+                               $this->apiCode = 'no' . $this->getParams()[0];
+                       } elseif ( substr( $key, 0, 8 ) === 'apiwarn-' ) {
+                               $this->apiCode = substr( $key, 8 );
+                       } elseif ( substr( $key, 0, 9 ) === 'apierror-' ) {
+                               $this->apiCode = substr( $key, 9 );
+                       } else {
+                               $this->apiCode = $key;
+                       }
+               }
+               return $this->apiCode;
        }
 
        public function setApiCode( $code, array $data = null ) {
+               if ( $code !== null && !( is_string( $code ) && $code !== '' ) ) {
+                       throw new InvalidArgumentException( "Invalid code \"$code\"" );
+               }
+
                $this->apiCode = $code;
                if ( $data !== null ) {
                        $this->setApiData( $data );
@@ -124,9 +206,25 @@ class ApiMessage extends Message implements IApiMessage {
         * @param Message|RawMessage|array|string $msg
         * @param string|null $code
         * @param array|null $data
-        * @return ApiMessage
+        * @return IApiMessage
         */
        public static function create( $msg, $code = null, array $data = null ) {
+               if ( is_array( $msg ) ) {
+                       // From StatusValue
+                       if ( isset( $msg['message'] ) ) {
+                               if ( isset( $msg['params'] ) ) {
+                                       $msg = array_merge( [ $msg['message'] ], $msg['params'] );
+                               } else {
+                                       $msg = [ $msg['message'] ];
+                               }
+                       }
+
+                       // Weirdness that comes in sometimes, including the above
+                       if ( $msg[0] instanceof MessageSpecifier ) {
+                               $msg = $msg[0];
+                       }
+               }
+
                if ( $msg instanceof IApiMessage ) {
                        return $msg;
                } elseif ( $msg instanceof RawMessage ) {
@@ -143,7 +241,6 @@ class ApiMessage extends Message implements IApiMessage {
         *  - string: passed to Message::__construct
         * @param string|null $code
         * @param array|null $data
-        * @return ApiMessage
         */
        public function __construct( $msg, $code = null, array $data = null ) {
                if ( $msg instanceof Message ) {
@@ -158,8 +255,7 @@ class ApiMessage extends Message implements IApiMessage {
                } else {
                        parent::__construct( $msg );
                }
-               $this->apiCode = $code;
-               $this->apiData = (array)$data;
+               $this->setApiCode( $code, $data );
        }
 }
 
@@ -192,7 +288,6 @@ class ApiRawMessage extends RawMessage implements IApiMessage {
                } else {
                        parent::__construct( $msg );
                }
-               $this->apiCode = $code;
-               $this->apiData = (array)$data;
+               $this->setApiCode( $code, $data );
        }
 }
index 29e67b0..7c8aa90 100644 (file)
@@ -41,23 +41,23 @@ class ApiMove extends ApiBase {
                if ( isset( $params['from'] ) ) {
                        $fromTitle = Title::newFromText( $params['from'] );
                        if ( !$fromTitle || $fromTitle->isExternal() ) {
-                               $this->dieUsageMsg( [ 'invalidtitle', $params['from'] ] );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $params['from'] ) ] );
                        }
                } elseif ( isset( $params['fromid'] ) ) {
                        $fromTitle = Title::newFromID( $params['fromid'] );
                        if ( !$fromTitle ) {
-                               $this->dieUsageMsg( [ 'nosuchpageid', $params['fromid'] ] );
+                               $this->dieWithError( [ 'apierror-nosuchpageid', $params['fromid'] ] );
                        }
                }
 
                if ( !$fromTitle->exists() ) {
-                       $this->dieUsageMsg( 'notanarticle' );
+                       $this->dieWithError( 'apierror-missingtitle' );
                }
                $fromTalk = $fromTitle->getTalkPage();
 
                $toTitle = Title::newFromText( $params['to'] );
                if ( !$toTitle || $toTitle->isExternal() ) {
-                       $this->dieUsageMsg( [ 'invalidtitle', $params['to'] ] );
+                       $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $params['to'] ) ] );
                }
                $toTalk = $toTitle->getTalkPage();
 
@@ -66,15 +66,15 @@ class ApiMove extends ApiBase {
                        && wfFindFile( $toTitle )
                ) {
                        if ( !$params['ignorewarnings'] && $user->isAllowed( 'reupload-shared' ) ) {
-                               $this->dieUsageMsg( 'sharedfile-exists' );
+                               $this->dieWithError( 'apierror-fileexists-sharedrepo-perm' );
                        } elseif ( !$user->isAllowed( 'reupload-shared' ) ) {
-                               $this->dieUsageMsg( 'cantoverwrite-sharedfile' );
+                               $this->dieWithError( 'apierror-cantoverwrite-sharedfile' );
                        }
                }
 
                // Rate limit
                if ( $user->pingLimiter( 'move' ) ) {
-                       $this->dieUsageMsg( 'actionthrottledtext' );
+                       $this->dieWithError( 'apierror-ratelimited' );
                }
 
                // Move the page
@@ -108,10 +108,8 @@ class ApiMove extends ApiBase {
                                $r['talkto'] = $toTalk->getPrefixedText();
                                $r['talkmoveoverredirect'] = $toTalkExists;
                        } else {
-                               // We're not gonna dieUsage() on failure, since we already changed something
-                               $error = $this->getErrorFromStatus( $status );
-                               $r['talkmove-error-code'] = $error[0];
-                               $r['talkmove-error-info'] = $error[1];
+                               // We're not going to dieWithError() on failure, since we already changed something
+                               $r['talkmove-errors'] = $this->getErrorFormatter()->arrayFromStatus( $status );
                        }
                }
 
@@ -184,7 +182,8 @@ class ApiMove extends ApiBase {
                $retval = [];
                $success = $fromTitle->moveSubpages( $toTitle, true, $reason, !$noredirect );
                if ( isset( $success[0] ) ) {
-                       return [ 'error' => $this->parseMsg( $success ) ];
+                       $status = $this->errorArrayToStatus( $success );
+                       return [ 'errors' => $this->getErrorFormatter()->arrayFromStatus( $status ) ];
                }
 
                // At least some pages could be moved
@@ -192,7 +191,8 @@ class ApiMove extends ApiBase {
                foreach ( $success as $oldTitle => $newTitle ) {
                        $r = [ 'from' => $oldTitle ];
                        if ( is_array( $newTitle ) ) {
-                               $r['error'] = $this->parseMsg( reset( $newTitle ) );
+                               $status = $this->errorArrayToStatus( $newTitle );
+                               $r['errors'] = $this->getErrorFormatter()->arrayFromStatus( $status );
                        } else {
                                // Success
                                $r['to'] = $newTitle;
index ace776c..e6fe27c 100644 (file)
@@ -391,14 +391,14 @@ class ApiOpenSearchFormatJson extends ApiFormatJson {
        }
 
        public function execute() {
-               if ( !$this->getResult()->getResultData( 'error' ) ) {
-                       $result = $this->getResult();
-
+               $result = $this->getResult();
+               if ( !$result->getResultData( 'error' ) && !$result->getResultData( 'errors' ) ) {
                        // Ignore warnings or treat as errors, as requested
                        $warnings = $result->removeValue( 'warnings', null );
                        if ( $this->warningsAsError && $warnings ) {
-                               $this->dieUsage(
-                                       'Warnings cannot be represented in OpenSearch JSON format', 'warnings', 0,
+                               $this->dieWithError(
+                                       'apierror-opensearch-json-warnings',
+                                       'warnings',
                                        [ 'warnings' => $warnings ]
                                );
                        }
index 8bfe447..466d186 100644 (file)
@@ -36,22 +36,26 @@ class ApiOptions extends ApiBase {
         */
        public function execute() {
                if ( $this->getUser()->isAnon() ) {
-                       $this->dieUsage( 'Anonymous users cannot change preferences', 'notloggedin' );
-               } elseif ( !$this->getUser()->isAllowed( 'editmyoptions' ) ) {
-                       $this->dieUsage( "You don't have permission to edit your options", 'permissiondenied' );
+                       $this->dieWithError(
+                               [ 'apierror-mustbeloggedin', $this->msg( 'action-editmyoptions' ) ], 'notloggedin'
+                       );
                }
 
+               $this->checkUserRightsAny( 'editmyoptions' );
+
                $params = $this->extractRequestParams();
                $changed = false;
 
                if ( isset( $params['optionvalue'] ) && !isset( $params['optionname'] ) ) {
-                       $this->dieUsageMsg( [ 'missingparam', 'optionname' ] );
+                       $this->dieWithError( [ 'apierror-missingparam', 'optionname' ] );
                }
 
                // Load the user from the master to reduce CAS errors on double post (T95839)
                $user = $this->getUser()->getInstanceForUpdate();
                if ( !$user ) {
-                       $this->dieUsage( 'Anonymous users cannot change preferences', 'notloggedin' );
+                       $this->dieWithError(
+                               [ 'apierror-mustbeloggedin', $this->msg( 'action-editmyoptions' ) ], 'notloggedin'
+                       );
                }
 
                if ( $params['reset'] ) {
@@ -71,7 +75,7 @@ class ApiOptions extends ApiBase {
                        $changes[$params['optionname']] = $newValue;
                }
                if ( !$changed && !count( $changes ) ) {
-                       $this->dieUsage( 'No changes were requested', 'nochanges' );
+                       $this->dieWithError( 'apierror-nochanges' );
                }
 
                $prefs = Preferences::getPreferences( $user, $this->getContext() );
@@ -98,26 +102,26 @@ class ApiOptions extends ApiBase {
                                case 'userjs':
                                        // Allow non-default preferences prefixed with 'userjs-', to be set by user scripts
                                        if ( strlen( $key ) > 255 ) {
-                                               $validation = 'key too long (no more than 255 bytes allowed)';
+                                               $validation = $this->msg( 'apiwarn-validationfailed-keytoolong', Message::numParam( 255 ) );
                                        } elseif ( preg_match( '/[^a-zA-Z0-9_-]/', $key ) !== 0 ) {
-                                               $validation = 'invalid key (only a-z, A-Z, 0-9, _, - allowed)';
+                                               $validation = $this->msg( 'apiwarn-validationfailed-badchars' );
                                        } else {
                                                $validation = true;
                                        }
                                        break;
                                case 'special':
-                                       $validation = 'cannot be set by this module';
+                                       $validation = $this->msg( 'apiwarn-validationfailed-cannotset' );
                                        break;
                                case 'unused':
                                default:
-                                       $validation = 'not a valid preference';
+                                       $validation = $this->msg( 'apiwarn-validationfailed-badpref' );
                                        break;
                        }
                        if ( $validation === true ) {
                                $user->setOption( $key, $value );
                                $changed = true;
                        } else {
-                               $this->setWarning( "Validation error for '$key': $validation" );
+                               $this->addWarning( [ 'apiwarn-validationfailed', wfEscapeWikitext( $key ), $validation ] );
                        }
                }
 
index 853a805..4cf896f 100644 (file)
@@ -155,10 +155,10 @@ class ApiPageSet extends ApiBase {
                        }
                        $generator = $dbSource->getModuleManager()->getModule( $generatorName, null, true );
                        if ( $generator === null ) {
-                               $this->dieUsage( 'Unknown generator=' . $generatorName, 'badgenerator' );
+                               $this->dieWithError( [ 'apierror-badgenerator-unknown', $generatorName ], 'badgenerator' );
                        }
                        if ( !$generator instanceof ApiQueryGeneratorBase ) {
-                               $this->dieUsage( "Module $generatorName cannot be used as a generator", 'badgenerator' );
+                               $this->dieWithError( [ 'apierror-badgenerator-notgenerator', $generatorName ], 'badgenerator' );
                        }
                        // Create a temporary pageset to store generator's output,
                        // add any additional fields generator may need, and execute pageset to populate titles/pageids
@@ -194,13 +194,27 @@ class ApiPageSet extends ApiBase {
                        }
                        if ( isset( $this->mParams['pageids'] ) ) {
                                if ( isset( $dataSource ) ) {
-                                       $this->dieUsage( "Cannot use 'pageids' at the same time as '$dataSource'", 'multisource' );
+                                       $this->dieWithError(
+                                               [
+                                                       'apierror-invalidparammix-cannotusewith',
+                                                       $this->encodeParamName( 'pageids' ),
+                                                       $this->encodeParamName( $dataSource )
+                                               ],
+                                               'multisource'
+                                       );
                                }
                                $dataSource = 'pageids';
                        }
                        if ( isset( $this->mParams['revids'] ) ) {
                                if ( isset( $dataSource ) ) {
-                                       $this->dieUsage( "Cannot use 'revids' at the same time as '$dataSource'", 'multisource' );
+                                       $this->dieWithError(
+                                               [
+                                                       'apierror-invalidparammix-cannotusewith',
+                                                       $this->encodeParamName( 'revids' ),
+                                                       $this->encodeParamName( $dataSource )
+                                               ],
+                                               'multisource'
+                                       );
                                }
                                $dataSource = 'revids';
                        }
@@ -216,9 +230,7 @@ class ApiPageSet extends ApiBase {
                                                break;
                                        case 'revids':
                                                if ( $this->mResolveRedirects ) {
-                                                       $this->setWarning( 'Redirect resolution cannot be used ' .
-                                                               'together with the revids= parameter. Any redirects ' .
-                                                               'the revids= point to have not been resolved.' );
+                                                       $this->addWarning( 'apiwarn-redirectsandrevids' );
                                                }
                                                $this->mResolveRedirects = false;
                                                $this->initFromRevIDs( $this->mParams['revids'] );
index ffc3fc2..a9b3dde 100644 (file)
@@ -66,14 +66,17 @@ class ApiParamInfo extends ApiBase {
                                if ( $submodules ) {
                                        try {
                                                $module = $this->getModuleFromPath( $path );
-                                       } catch ( UsageException $ex ) {
-                                               $this->setWarning( $ex->getMessage() );
+                                       } catch ( ApiUsageException $ex ) {
+                                               foreach ( $ex->getStatusValue()->getErrors() as $error ) {
+                                                       $this->addWarning( $error );
+                                               }
+                                               continue;
                                        }
                                        $submodules = $this->listAllSubmodules( $module, $recursive );
                                        if ( $submodules ) {
                                                $modules = array_merge( $modules, $submodules );
                                        } else {
-                                               $this->setWarning( "Module $path has no submodules" );
+                                               $this->addWarning( [ 'apierror-badmodule-nosubmodules', $path ], 'badmodule' );
                                        }
                                } else {
                                        $modules[] = $path;
@@ -108,8 +111,10 @@ class ApiParamInfo extends ApiBase {
                foreach ( $modules as $m ) {
                        try {
                                $module = $this->getModuleFromPath( $m );
-                       } catch ( UsageException $ex ) {
-                               $this->setWarning( $ex->getMessage() );
+                       } catch ( ApiUsageException $ex ) {
+                               foreach ( $ex->getStatusValue()->getErrors() as $error ) {
+                                       $this->addWarning( $error );
+                               }
                                continue;
                        }
                        $key = 'modules';
index 0cad5de..2263b8f 100644 (file)
@@ -36,18 +36,18 @@ class ApiParse extends ApiBase {
        /** @var Content $pstContent */
        private $pstContent = null;
 
-       private function checkReadPermissions( Title $title ) {
-               if ( !$title->userCan( 'read', $this->getUser() ) ) {
-                       $this->dieUsage( "You don't have permission to view this page", 'permissiondenied' );
-               }
-       }
-
        public function execute() {
                // The data is hot but user-dependent, like page views, so we set vary cookies
                $this->getMain()->setCacheMode( 'anon-public-user-private' );
 
                // Get parameters
                $params = $this->extractRequestParams();
+
+               // No easy way to say that text & title are allowed together while the
+               // rest aren't, so just do it in two calls.
+               $this->requireMaxOneParameter( $params, 'page', 'pageid', 'oldid', 'text' );
+               $this->requireMaxOneParameter( $params, 'page', 'pageid', 'oldid', 'title' );
+
                $text = $params['text'];
                $title = $params['title'];
                if ( $title === null ) {
@@ -65,21 +65,12 @@ class ApiParse extends ApiBase {
                $model = $params['contentmodel'];
                $format = $params['contentformat'];
 
-               if ( !is_null( $page ) && ( !is_null( $text ) || $titleProvided ) ) {
-                       $this->dieUsage(
-                               'The page parameter cannot be used together with the text and title parameters',
-                               'params'
-                       );
-               }
-
                $prop = array_flip( $params['prop'] );
 
                if ( isset( $params['section'] ) ) {
                        $this->section = $params['section'];
                        if ( !preg_match( '/^((T-)?\d+|new)$/', $this->section ) ) {
-                               $this->dieUsage(
-                                       'The section parameter must be a valid section id or "new"', 'invalidsection'
-                               );
+                               $this->dieWithError( 'apierror-invalidsection' );
                        }
                } else {
                        $this->section = false;
@@ -97,21 +88,20 @@ class ApiParse extends ApiBase {
 
                if ( !is_null( $oldid ) || !is_null( $pageid ) || !is_null( $page ) ) {
                        if ( $this->section === 'new' ) {
-                                       $this->dieUsage(
-                                               'section=new cannot be combined with oldid, pageid or page parameters. ' .
-                                               'Please use text', 'params'
-                                       );
+                               $this->dieWithError( 'apierror-invalidparammix-parse-new-section', 'invalidparammix' );
                        }
                        if ( !is_null( $oldid ) ) {
                                // Don't use the parser cache
                                $rev = Revision::newFromId( $oldid );
                                if ( !$rev ) {
-                                       $this->dieUsage( "There is no revision ID $oldid", 'missingrev' );
+                                       $this->dieWithError( [ 'apierror-nosuchrevid', $oldid ] );
                                }
 
-                               $this->checkReadPermissions( $rev->getTitle() );
+                               $this->checkTitleUserPermissions( $rev->getTitle(), 'read' );
                                if ( !$rev->userCan( Revision::DELETED_TEXT, $this->getUser() ) ) {
-                                       $this->dieUsage( "You don't have permission to view deleted revisions", 'permissiondenied' );
+                                       $this->dieWithError(
+                                               [ 'apierror-permissiondenied', $this->msg( 'action-deletedtext' ) ]
+                                       );
                                }
 
                                $titleObj = $rev->getTitle();
@@ -131,7 +121,9 @@ class ApiParse extends ApiBase {
                                        $this->content = $rev->getContent( Revision::FOR_THIS_USER, $this->getUser() );
 
                                        if ( $this->section !== false ) {
-                                               $this->content = $this->getSectionContent( $this->content, 'r' . $rev->getId() );
+                                               $this->content = $this->getSectionContent(
+                                                       $this->content, $this->msg( 'revid', $rev->getId() )
+                                               );
                                        }
 
                                        // Should we save old revision parses to the parser cache?
@@ -167,10 +159,10 @@ class ApiParse extends ApiBase {
                                $pageObj = $this->getTitleOrPageId( $pageParams, 'fromdb' );
                                $titleObj = $pageObj->getTitle();
                                if ( !$titleObj || !$titleObj->exists() ) {
-                                       $this->dieUsage( "The page you specified doesn't exist", 'missingtitle' );
+                                       $this->dieWithError( 'apierror-missingtitle' );
                                }
 
-                               $this->checkReadPermissions( $titleObj );
+                               $this->checkTitleUserPermissions( $titleObj, 'read' );
                                $wgTitle = $titleObj;
 
                                if ( isset( $prop['revid'] ) ) {
@@ -201,7 +193,7 @@ class ApiParse extends ApiBase {
                } else { // Not $oldid, $pageid, $page. Hence based on $text
                        $titleObj = Title::newFromText( $title );
                        if ( !$titleObj || $titleObj->isExternal() ) {
-                               $this->dieUsageMsg( [ 'invalidtitle', $title ] );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $title ) ] );
                        }
                        $wgTitle = $titleObj;
                        if ( $titleObj->canExist() ) {
@@ -217,10 +209,7 @@ class ApiParse extends ApiBase {
 
                        if ( !$textProvided ) {
                                if ( $titleProvided && ( $prop || $params['generatexml'] ) ) {
-                                       $this->setWarning(
-                                               "'title' used without 'text', and parsed page properties were requested " .
-                                               "(did you mean to use 'page' instead of 'title'?)"
-                                       );
+                                       $this->addWarning( 'apiwarn-parse-titlewithouttext' );
                                }
                                // Prevent warning from ContentHandler::makeContent()
                                $text = '';
@@ -230,13 +219,17 @@ class ApiParse extends ApiBase {
                        // API title, but default to wikitext to keep BC.
                        if ( $textProvided && !$titleProvided && is_null( $model ) ) {
                                $model = CONTENT_MODEL_WIKITEXT;
-                               $this->setWarning( "No 'title' or 'contentmodel' was given, assuming $model." );
+                               $this->addWarning( [ 'apiwarn-parse-nocontentmodel', $model ] );
                        }
 
                        try {
                                $this->content = ContentHandler::makeContent( $text, $titleObj, $model, $format );
                        } catch ( MWContentSerializationException $ex ) {
-                               $this->dieUsage( $ex->getMessage(), 'parseerror' );
+                               // @todo: Internationalize MWContentSerializationException
+                               $this->dieWithError(
+                                       [ 'apierror-contentserializationexception', wfEscapeWikiText( $ex->getMessage() ) ],
+                                       'parseerror'
+                               );
                        }
 
                        if ( $this->section !== false ) {
@@ -357,10 +350,7 @@ class ApiParse extends ApiBase {
 
                if ( isset( $prop['headitems'] ) ) {
                        $result_array['headitems'] = $this->formatHeadItems( $p_result->getHeadItems() );
-                       $this->logFeatureUsage( 'action=parse&prop=headitems' );
-                       $this->setWarning( 'headitems is deprecated since MediaWiki 1.28. '
-                               . 'Use prop=headhtml when creating new HTML documents, or '
-                               . 'prop=modules|jsconfigvars when updating a document client-side.' );
+                       $this->addDeprecation( 'apiwarn-deprecation-parse-headitems', 'action=parse&prop=headitems' );
                }
 
                if ( isset( $prop['headhtml'] ) ) {
@@ -397,9 +387,7 @@ class ApiParse extends ApiBase {
 
                if ( isset( $prop['modules'] ) &&
                        !isset( $prop['jsconfigvars'] ) && !isset( $prop['encodedjsconfigvars'] ) ) {
-                       $this->setWarning( 'Property "modules" was set but not "jsconfigvars" ' .
-                               'or "encodedjsconfigvars". Configuration variables are necessary ' .
-                               'for proper module usage.' );
+                       $this->addWarning( 'apiwarn-moduleswithoutvars' );
                }
 
                if ( isset( $prop['indicators'] ) ) {
@@ -435,7 +423,7 @@ class ApiParse extends ApiBase {
 
                if ( isset( $prop['parsetree'] ) || $params['generatexml'] ) {
                        if ( $this->content->getModel() != CONTENT_MODEL_WIKITEXT ) {
-                               $this->dieUsage( 'parsetree is only supported for wikitext content', 'notwikitext' );
+                               $this->dieWithError( 'apierror-parsetree-notwikitext', 'notwikitext' );
                        }
 
                        $wgParser->startExternalParse( $titleObj, $popts, Parser::OT_PREPROCESS );
@@ -516,7 +504,7 @@ class ApiParse extends ApiBase {
                // getParserOutput will save to Parser cache if able
                $pout = $page->getParserOutput( $popts );
                if ( !$pout ) {
-                       $this->dieUsage( "There is no revision ID {$page->getLatest()}", 'missingrev' );
+                       $this->dieWithError( [ 'apierror-nosuchrevid', $page->getLatest() ] );
                }
                if ( $getWikitext ) {
                        $this->content = $page->getContent( Revision::RAW );
@@ -538,7 +526,9 @@ class ApiParse extends ApiBase {
                if ( $this->section !== false && $content !== null ) {
                        $content = $this->getSectionContent(
                                $content,
-                               !is_null( $pageId ) ? 'page id ' . $pageId : $page->getTitle()->getPrefixedText()
+                               !is_null( $pageId )
+                                       ? $this->msg( 'pageid', $pageId )
+                                       : $page->getTitle()->getPrefixedText()
                        );
                }
                return $content;
@@ -548,17 +538,17 @@ class ApiParse extends ApiBase {
         * Extract the requested section from the given Content
         *
         * @param Content $content
-        * @param string $what Identifies the content in error messages, e.g. page title.
+        * @param string|Message $what Identifies the content in error messages, e.g. page title.
         * @return Content|bool
         */
        private function getSectionContent( Content $content, $what ) {
                // Not cached (save or load)
                $section = $content->getSection( $this->section );
                if ( $section === false ) {
-                       $this->dieUsage( "There is no section {$this->section} in $what", 'nosuchsection' );
+                       $this->dieWithError( [ 'apierror-nosuchsection-what', $this->section, $what ], 'nosuchsection' );
                }
                if ( $section === null ) {
-                       $this->dieUsage( "Sections are not supported by $what", 'nosuchsection' );
+                       $this->dieWithError( [ 'apierror-sectionsnotsupported-what', $what ], 'nosuchsection' );
                        $section = false;
                }
 
index 6252882..c33542f 100644 (file)
@@ -40,19 +40,16 @@ class ApiPatrol extends ApiBase {
                if ( isset( $params['rcid'] ) ) {
                        $rc = RecentChange::newFromId( $params['rcid'] );
                        if ( !$rc ) {
-                               $this->dieUsageMsg( [ 'nosuchrcid', $params['rcid'] ] );
+                               $this->dieWithError( [ 'apierror-nosuchrcid', $params['rcid'] ] );
                        }
                } else {
                        $rev = Revision::newFromId( $params['revid'] );
                        if ( !$rev ) {
-                               $this->dieUsageMsg( [ 'nosuchrevid', $params['revid'] ] );
+                               $this->dieWithError( [ 'apierror-nosuchrevid', $params['revid'] ] );
                        }
                        $rc = $rev->getRecentChange();
                        if ( !$rc ) {
-                               $this->dieUsage(
-                                       'The revision ' . $params['revid'] . " can't be patrolled as it's too old",
-                                       'notpatrollable'
-                               );
+                               $this->dieWithError( [ 'apierror-notpatrollable', $params['revid'] ] );
                        }
                }
 
@@ -70,7 +67,7 @@ class ApiPatrol extends ApiBase {
                $retval = $rc->doMarkPatrolled( $user, false, $tags );
 
                if ( $retval ) {
-                       $this->dieUsageMsg( reset( $retval ) );
+                       $this->dieStatus( $this->errorArrayToStatus( $retval, $user ) );
                }
 
                $result = [ 'rcid' => intval( $rc->getAttribute( 'rc_id' ) ) ];
index d289060..746dc9a 100644 (file)
@@ -36,11 +36,7 @@ class ApiProtect extends ApiBase {
                $pageObj = $this->getTitleOrPageId( $params, 'fromdbmaster' );
                $titleObj = $pageObj->getTitle();
 
-               $errors = $titleObj->getUserPermissionsErrors( 'protect', $this->getUser() );
-               if ( $errors ) {
-                       // We don't care about multiple errors, just report one of them
-                       $this->dieUsageMsg( reset( $errors ) );
-               }
+               $this->checkTitleUserPermissions( $titleObj, 'protect' );
 
                $user = $this->getUser();
                $tags = $params['tags'];
@@ -58,8 +54,8 @@ class ApiProtect extends ApiBase {
                        if ( count( $expiry ) == 1 ) {
                                $expiry = array_fill( 0, count( $params['protections'] ), $expiry[0] );
                        } else {
-                               $this->dieUsageMsg( [
-                                       'toofewexpiries',
+                               $this->dieWithError( [
+                                       'apierror-toofewexpiries',
                                        count( $expiry ),
                                        count( $params['protections'] )
                                ] );
@@ -76,17 +72,17 @@ class ApiProtect extends ApiBase {
                        $protections[$p[0]] = ( $p[1] == 'all' ? '' : $p[1] );
 
                        if ( $titleObj->exists() && $p[0] == 'create' ) {
-                               $this->dieUsageMsg( 'create-titleexists' );
+                               $this->dieWithError( 'apierror-create-titleexists' );
                        }
                        if ( !$titleObj->exists() && $p[0] != 'create' ) {
-                               $this->dieUsageMsg( 'missingtitle-createonly' );
+                               $this->dieWithError( 'apierror-missingtitle-createonly' );
                        }
 
                        if ( !in_array( $p[0], $restrictionTypes ) && $p[0] != 'create' ) {
-                               $this->dieUsageMsg( [ 'protect-invalidaction', $p[0] ] );
+                               $this->dieWithError( [ 'apierror-protect-invalidaction', wfEscapeWikiText( $p[0] ) ] );
                        }
                        if ( !in_array( $p[1], $this->getConfig()->get( 'RestrictionLevels' ) ) && $p[1] != 'all' ) {
-                               $this->dieUsageMsg( [ 'protect-invalidlevel', $p[1] ] );
+                               $this->dieWithError( [ 'apierror-protect-invalidlevel', wfEscapeWikiText( $p[1] ) ] );
                        }
 
                        if ( wfIsInfinity( $expiry[$i] ) ) {
@@ -94,12 +90,12 @@ class ApiProtect extends ApiBase {
                        } else {
                                $exp = strtotime( $expiry[$i] );
                                if ( $exp < 0 || !$exp ) {
-                                       $this->dieUsageMsg( [ 'invalidexpiry', $expiry[$i] ] );
+                                       $this->dieWithError( [ 'apierror-invalidexpiry', wfEscapeWikiText( $expiry[$i] ) ] );
                                }
 
                                $exp = wfTimestamp( TS_MW, $exp );
                                if ( $exp < wfTimestampNow() ) {
-                                       $this->dieUsageMsg( [ 'pastexpiry', $expiry[$i] ] );
+                                       $this->dieWithError( [ 'apierror-pastexpiry', wfEscapeWikiText( $expiry[$i] ) ] );
                                }
                                $expiryarray[$p[0]] = $exp;
                        }
index 8bbd88d..324d030 100644 (file)
@@ -39,8 +39,7 @@ class ApiPurge extends ApiBase {
        public function execute() {
                $main = $this->getMain();
                if ( !$main->isInternalMode() && !$main->getRequest()->wasPosted() ) {
-                       $this->logFeatureUsage( 'purge-via-GET' );
-                       $this->setWarning( 'Use of action=purge via GET is deprecated. Use POST instead.' );
+                       $this->addDeprecation( 'apiwarn-deprecation-purge-get', 'purge-via-GET' );
                }
 
                $params = $this->extractRequestParams();
@@ -69,8 +68,7 @@ class ApiPurge extends ApiBase {
                                $page->doPurge( $flags );
                                $r['purged'] = true;
                        } else {
-                               $error = $this->parseMsg( [ 'actionthrottledtext' ] );
-                               $this->setWarning( $error['info'] );
+                               $this->addWarning( 'apierror-ratelimited' );
                        }
 
                        if ( $forceLinkUpdate || $forceRecursiveLinkUpdate ) {
@@ -114,8 +112,7 @@ class ApiPurge extends ApiBase {
                                                }
                                        }
                                } else {
-                                       $error = $this->parseMsg( [ 'actionthrottledtext' ] );
-                                       $this->setWarning( $error['info'] );
+                                       $this->addWarning( 'apierror-ratelimited' );
                                        $forceLinkUpdate = false;
                                }
                        }
index 16bd725..8196cfa 100644 (file)
@@ -310,7 +310,7 @@ class ApiQuery extends ApiBase {
                                        ApiBase::dieDebug( __METHOD__, 'Error instantiating module' );
                                }
                                if ( !$wasPosted && $instance->mustBePosted() ) {
-                                       $this->dieUsageMsgOrDebug( [ 'mustbeposted', $moduleName ] );
+                                       $this->dieWithErrorOrDebug( [ 'apierror-mustbeposted', $moduleName ] );
                                }
                                // Ignore duplicates. TODO 2.0: die()?
                                if ( !array_key_exists( $moduleName, $modules ) ) {
@@ -415,11 +415,7 @@ class ApiQuery extends ApiBase {
                }
 
                if ( !$fit ) {
-                       $this->dieUsage(
-                               'The value of $wgAPIMaxResultSize on this wiki is ' .
-                                       'too small to hold basic result information',
-                               'badconfig'
-                       );
+                       $this->dieWithError( 'apierror-badconfig-resulttoosmall', 'badconfig' );
                }
 
                if ( $this->mParams['export'] ) {
index 3073a95..b09b977 100644 (file)
@@ -41,15 +41,10 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
         * @return void
         */
        protected function run( ApiPageSet $resultPageSet = null ) {
-               $user = $this->getUser();
                // Before doing anything at all, let's check permissions
-               if ( !$user->isAllowed( 'deletedhistory' ) ) {
-                       $this->dieUsage(
-                               'You don\'t have permission to view deleted revision information',
-                               'permissiondenied'
-                       );
-               }
+               $this->checkUserRightsAny( 'deletedhistory' );
 
+               $user = $this->getUser();
                $db = $this->getDB();
                $params = $this->extractRequestParams( false );
 
@@ -75,16 +70,20 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
                        foreach ( [ 'from', 'to', 'prefix', 'excludeuser' ] as $param ) {
                                if ( !is_null( $params[$param] ) ) {
                                        $p = $this->getModulePrefix();
-                                       $this->dieUsage( "The '{$p}{$param}' parameter cannot be used with '{$p}user'",
-                                               'badparams' );
+                                       $this->dieWithError(
+                                               [ 'apierror-invalidparammix-cannotusewith', $p.$param, "{$p}user" ],
+                                               'invalidparammix'
+                                       );
                                }
                        }
                } else {
                        foreach ( [ 'start', 'end' ] as $param ) {
                                if ( !is_null( $params[$param] ) ) {
                                        $p = $this->getModulePrefix();
-                                       $this->dieUsage( "The '{$p}{$param}' parameter may only be used with '{$p}user'",
-                                               'badparams' );
+                                       $this->dieWithError(
+                                               [ 'apierror-invalidparammix-mustusewith', $p.$param, "{$p}user" ],
+                                               'invalidparammix'
+                                       );
                                }
                        }
                }
@@ -100,7 +99,7 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
                                $optimizeGenerateTitles = true;
                        } else {
                                $p = $this->getModulePrefix();
-                               $this->setWarning( "For better performance when generating titles, set {$p}dir=newer" );
+                               $this->addWarning( [ 'apiwarn-alldeletedrevisions-performance', $p ], 'performance' );
                        }
                }
 
@@ -148,12 +147,7 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
                        $this->addFields( [ 'ar_text', 'ar_flags', 'old_text', 'old_flags' ] );
 
                        // This also means stricter restrictions
-                       if ( !$user->isAllowedAny( 'undelete', 'deletedtext' ) ) {
-                               $this->dieUsage(
-                                       'You don\'t have permission to view deleted revision content',
-                                       'permissiondenied'
-                               );
-                       }
+                       $this->checkUserRightsAny( [ 'deletedtext', 'undelete' ] );
                }
 
                $miser_ns = null;
index 8734f38..e3e5ed6 100644 (file)
@@ -64,11 +64,7 @@ class ApiQueryAllImages extends ApiQueryGeneratorBase {
         */
        public function executeGenerator( $resultPageSet ) {
                if ( $resultPageSet->isResolvingRedirects() ) {
-                       $this->dieUsage(
-                               'Use "gaifilterredir=nonredirects" option instead of "redirects" ' .
-                                       'when using allimages as a generator',
-                               'params'
-                       );
+                       $this->dieWithError( 'apierror-allimages-redirect', 'invalidparammix' );
                }
 
                $this->run( $resultPageSet );
@@ -81,10 +77,7 @@ class ApiQueryAllImages extends ApiQueryGeneratorBase {
        private function run( $resultPageSet = null ) {
                $repo = $this->mRepo;
                if ( !$repo instanceof LocalRepo ) {
-                       $this->dieUsage(
-                               'Local file repository does not support querying all images',
-                               'unsupportedrepo'
-                       );
+                       $this->dieWithError( 'apierror-unsupportedrepo' );
                }
 
                $prefix = $this->getModulePrefix();
@@ -109,16 +102,24 @@ class ApiQueryAllImages extends ApiQueryGeneratorBase {
                        $disallowed = [ 'start', 'end', 'user' ];
                        foreach ( $disallowed as $pname ) {
                                if ( isset( $params[$pname] ) ) {
-                                       $this->dieUsage(
-                                               "Parameter '{$prefix}{$pname}' can only be used with {$prefix}sort=timestamp",
-                                               'badparams'
+                                       $this->dieWithError(
+                                               [
+                                                       'apierror-invalidparammix-mustusewith',
+                                                       "{$prefix}{$pname}",
+                                                       "{$prefix}sort=timestamp"
+                                               ],
+                                               'invalidparammix'
                                        );
                                }
                        }
                        if ( $params['filterbots'] != 'all' ) {
-                               $this->dieUsage(
-                                       "Parameter '{$prefix}filterbots' can only be used with {$prefix}sort=timestamp",
-                                       'badparams'
+                               $this->dieWithError(
+                                       [
+                                               'apierror-invalidparammix-mustusewith',
+                                               "{$prefix}filterbots",
+                                               "{$prefix}sort=timestamp"
+                                       ],
+                                       'invalidparammix'
                                );
                        }
 
@@ -146,18 +147,21 @@ class ApiQueryAllImages extends ApiQueryGeneratorBase {
                        $disallowed = [ 'from', 'to', 'prefix' ];
                        foreach ( $disallowed as $pname ) {
                                if ( isset( $params[$pname] ) ) {
-                                       $this->dieUsage(
-                                               "Parameter '{$prefix}{$pname}' can only be used with {$prefix}sort=name",
-                                               'badparams'
+                                       $this->dieWithError(
+                                               [
+                                                       'apierror-invalidparammix-mustusewith',
+                                                       "{$prefix}{$pname}",
+                                                       "{$prefix}sort=name"
+                                               ],
+                                               'invalidparammix'
                                        );
                                }
                        }
                        if ( !is_null( $params['user'] ) && $params['filterbots'] != 'all' ) {
                                // Since filterbots checks if each user has the bot right, it
                                // doesn't make sense to use it with user
-                               $this->dieUsage(
-                                       "Parameters '{$prefix}user' and '{$prefix}filterbots' cannot be used together",
-                                       'badparams'
+                               $this->dieWithError(
+                                       [ 'apierror-invalidparammix-cannotusewith', "{$prefix}user", "{$prefix}filterbots" ]
                                );
                        }
 
@@ -214,13 +218,13 @@ class ApiQueryAllImages extends ApiQueryGeneratorBase {
                if ( isset( $params['sha1'] ) ) {
                        $sha1 = strtolower( $params['sha1'] );
                        if ( !$this->validateSha1Hash( $sha1 ) ) {
-                               $this->dieUsage( 'The SHA1 hash provided is not valid', 'invalidsha1hash' );
+                               $this->dieWithError( 'apierror-invalidsha1hash' );
                        }
                        $sha1 = Wikimedia\base_convert( $sha1, 16, 36, 31 );
                } elseif ( isset( $params['sha1base36'] ) ) {
                        $sha1 = strtolower( $params['sha1base36'] );
                        if ( !$this->validateSha1Base36Hash( $sha1 ) ) {
-                               $this->dieUsage( 'The SHA1Base36 hash provided is not valid', 'invalidsha1base36hash' );
+                               $this->dieWithError( 'apierror-invalidsha1base36hash' );
                        }
                }
                if ( $sha1 ) {
@@ -229,7 +233,7 @@ class ApiQueryAllImages extends ApiQueryGeneratorBase {
 
                if ( !is_null( $params['mime'] ) ) {
                        if ( $this->getConfig()->get( 'MiserMode' ) ) {
-                               $this->dieUsage( 'MIME search disabled in Miser Mode', 'mimesearchdisabled' );
+                               $this->dieWithError( 'apierror-mimesearchdisabled' );
                        }
 
                        $mimeConds = [];
index ac90605..c3636c6 100644 (file)
@@ -116,9 +116,13 @@ class ApiQueryAllLinks extends ApiQueryGeneratorBase {
                        $matches = array_intersect_key( $prop, $this->props + [ 'ids' => 1 ] );
                        if ( $matches ) {
                                $p = $this->getModulePrefix();
-                               $this->dieUsage(
-                                       "Cannot use {$p}prop=" . implode( '|', array_keys( $matches ) ) . " with {$p}unique",
-                                       'params'
+                               $this->dieWithError(
+                                       [
+                                               'apierror-invalidparammix-cannotusewith',
+                                               "{$p}prop=" . implode( '|', array_keys( $matches ) ),
+                                               "{$p}unique"
+                                       ],
+                                       'invalidparammix'
                                );
                        }
                        $this->addOption( 'DISTINCT' );
index e0ba4ea..244effc 100644 (file)
@@ -41,7 +41,9 @@ class ApiQueryAllMessages extends ApiQueryBase {
                if ( is_null( $params['lang'] ) ) {
                        $langObj = $this->getLanguage();
                } elseif ( !Language::isValidCode( $params['lang'] ) ) {
-                       $this->dieUsage( 'Invalid language code for parameter lang', 'invalidlang' );
+                       $this->dieWithError(
+                               [ 'apierror-invalidlang', $this->encodeParamName( 'lang' ) ], 'invalidlang'
+                       );
                } else {
                        $langObj = Language::factory( $params['lang'] );
                }
@@ -50,7 +52,7 @@ class ApiQueryAllMessages extends ApiQueryBase {
                        if ( !is_null( $params['title'] ) ) {
                                $title = Title::newFromText( $params['title'] );
                                if ( !$title || $title->isExternal() ) {
-                                       $this->dieUsageMsg( [ 'invalidtitle', $params['title'] ] );
+                                       $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $params['title'] ) ] );
                                }
                        } else {
                                $title = Title::newFromText( 'API' );
index 6a0f124..7460bd5 100644 (file)
@@ -50,11 +50,7 @@ class ApiQueryAllPages extends ApiQueryGeneratorBase {
         */
        public function executeGenerator( $resultPageSet ) {
                if ( $resultPageSet->isResolvingRedirects() ) {
-                       $this->dieUsage(
-                               'Use "gapfilterredir=nonredirects" option instead of "redirects" ' .
-                                       'when using allpages as a generator',
-                               'params'
-                       );
+                       $this->dieWithError( 'apierror-allpages-generator-redirects', 'params' );
                }
 
                $this->run( $resultPageSet );
@@ -157,7 +153,9 @@ class ApiQueryAllPages extends ApiQueryGeneratorBase {
 
                        $this->addOption( 'DISTINCT' );
                } elseif ( isset( $params['prlevel'] ) ) {
-                       $this->dieUsage( 'prlevel may not be used without prtype', 'params' );
+                       $this->dieWithError(
+                               [ 'apierror-invalidparammix-mustusewith', 'prlevel', 'prtype' ], 'invalidparammix'
+                       );
                }
 
                if ( $params['filterlanglinks'] == 'withoutlanglinks' ) {
index b7ed9dd..2e2ac32 100644 (file)
@@ -110,9 +110,7 @@ class ApiQueryAllUsers extends ApiQueryBase {
                        }
                }
 
-               if ( !is_null( $params['group'] ) && !is_null( $params['excludegroup'] ) ) {
-                       $this->dieUsage( 'group and excludegroup cannot be used together', 'group-excludegroup' );
-               }
+               $this->requireMaxOneParameter( $params, 'group', 'excludegroup' );
 
                if ( !is_null( $params['group'] ) && count( $params['group'] ) ) {
                        // Filter only users that belong to a given group. This might
index fb502e4..4c32320 100644 (file)
@@ -348,8 +348,8 @@ class ApiQueryBacklinks extends ApiQueryGeneratorBase {
 
                // only image titles are allowed for the root in imageinfo mode
                if ( !$this->hasNS && $this->rootTitle->getNamespace() !== NS_FILE ) {
-                       $this->dieUsage(
-                               "The title for {$this->getModuleName()} query must be a file",
+                       $this->dieWithError(
+                               [ 'apierror-imageusage-badtitle', $this->getModuleName() ],
                                'bad_image_title'
                        );
                }
index 8e89c32..ef7b9af 100644 (file)
@@ -238,7 +238,7 @@ class ApiQueryBacklinksprop extends ApiQueryGeneratorBase {
                        if ( isset( $show['fragment'] ) && isset( $show['!fragment'] ) ||
                                isset( $show['redirect'] ) && isset( $show['!redirect'] )
                        ) {
-                               $this->dieUsageMsg( 'show' );
+                               $this->dieWithError( 'apierror-show' );
                        }
                        $this->addWhereIf( "rd_fragment != $emptyString", isset( $show['fragment'] ) );
                        $this->addWhereIf(
index bba5375..af2aed5 100644 (file)
@@ -421,7 +421,7 @@ abstract class ApiQueryBase extends ApiBase {
 
                        $likeQuery = LinkFilter::makeLikeArray( $query, $protocol );
                        if ( !$likeQuery ) {
-                               $this->dieUsage( 'Invalid query', 'bad_query' );
+                               $this->dieWithError( 'apierror-badquery' );
                        }
 
                        $likeQuery = LinkFilter::keepOneWildcard( $likeQuery );
@@ -547,7 +547,7 @@ abstract class ApiQueryBase extends ApiBase {
                $t = Title::makeTitleSafe( $namespace, $titlePart . 'x' );
                if ( !$t || $t->hasFragment() ) {
                        // Invalid title (e.g. bad chars) or contained a '#'.
-                       $this->dieUsageMsg( [ 'invalidtitle', $titlePart ] );
+                       $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $titlePart ) ] );
                }
                if ( $namespace != $t->getNamespace() || $t->isExternal() ) {
                        // This can happen in two cases. First, if you call titlePartToKey with a title part
@@ -555,7 +555,7 @@ abstract class ApiQueryBase extends ApiBase {
                        // difficult to handle such a case. Such cases cannot exist and are therefore treated
                        // as invalid user input. The second case is when somebody specifies a title interwiki
                        // prefix.
-                       $this->dieUsageMsg( [ 'invalidtitle', $titlePart ] );
+                       $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $titlePart ) ] );
                }
 
                return substr( $t->getDBkey(), 0, -1 );
@@ -573,7 +573,7 @@ abstract class ApiQueryBase extends ApiBase {
                $t = Title::newFromText( $titlePart . 'x', $defaultNamespace );
                if ( !$t || $t->hasFragment() || $t->isExternal() ) {
                        // Invalid title (e.g. bad chars) or contained a '#'.
-                       $this->dieUsageMsg( [ 'invalidtitle', $titlePart ] );
+                       $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $titlePart ) ] );
                }
 
                return [ $t->getNamespace(), substr( $t->getDBkey(), 0, -1 ) ];
index 5d7c664..ef79efd 100644 (file)
@@ -114,16 +114,13 @@ class ApiQueryBlocks extends ApiQueryBase {
                                $cidrLimit = $blockCIDRLimit['IPv6'];
                                $prefixLen = 3; // IP::toHex output is prefixed with "v6-"
                        } else {
-                               $this->dieUsage( 'IP parameter is not valid', 'param_ip' );
+                               $this->dieWithError( 'apierror-badip', 'param_ip' );
                        }
 
                        # Check range validity, if it's a CIDR
                        list( $ip, $range ) = IP::parseCIDR( $params['ip'] );
                        if ( $ip !== false && $range !== false && $range < $cidrLimit ) {
-                               $this->dieUsage(
-                                       "$type CIDR ranges broader than /$cidrLimit are not accepted",
-                                       'cidrtoobroad'
-                               );
+                               $this->dieWithError( [ 'apierror-cidrtoobroad', $type, $cidrLimit ] );
                        }
 
                        # Let IP::parseRange handle calculating $upper, instead of duplicating the logic here.
@@ -154,7 +151,7 @@ class ApiQueryBlocks extends ApiQueryBase {
                                || ( isset( $show['range'] ) && isset( $show['!range'] ) )
                                || ( isset( $show['temp'] ) && isset( $show['!temp'] ) )
                        ) {
-                               $this->dieUsageMsg( 'show' );
+                               $this->dieWithError( 'apierror-show' );
                        }
 
                        $this->addWhereIf( 'ipb_user = 0', isset( $show['!account'] ) );
@@ -237,13 +234,19 @@ class ApiQueryBlocks extends ApiQueryBase {
 
        protected function prepareUsername( $user ) {
                if ( !$user ) {
-                       $this->dieUsage( 'User parameter may not be empty', 'param_user' );
+                       $encParamName = $this->encodeParamName( 'users' );
+                       $this->dieWithError( [ 'apierror-baduser', $encParamName, wfEscapeWikiText( $user ) ],
+                               "baduser_{$encParamName}"
+                       );
                }
                $name = User::isIP( $user )
                        ? $user
                        : User::getCanonicalName( $user, 'valid' );
                if ( $name === false ) {
-                       $this->dieUsage( "User name {$user} is not valid", 'param_user' );
+                       $encParamName = $this->encodeParamName( 'users' );
+                       $this->dieWithError( [ 'apierror-baduser', $encParamName, wfEscapeWikiText( $user ) ],
+                               "baduser_{$encParamName}"
+                       );
                }
                return $name;
        }
index 63d0f6d..f2498ca 100644 (file)
@@ -74,7 +74,7 @@ class ApiQueryCategories extends ApiQueryGeneratorBase {
                        foreach ( $params['categories'] as $cat ) {
                                $title = Title::newFromText( $cat );
                                if ( !$title || $title->getNamespace() != NS_CATEGORY ) {
-                                       $this->setWarning( "\"$cat\" is not a category" );
+                                       $this->addWarning( [ 'apiwarn-invalidcategory', wfEscapeWikiText( $cat ) ] );
                                } else {
                                        $cats[] = $title->getDBkey();
                                }
@@ -96,7 +96,7 @@ class ApiQueryCategories extends ApiQueryGeneratorBase {
                }
 
                if ( isset( $show['hidden'] ) && isset( $show['!hidden'] ) ) {
-                       $this->dieUsageMsg( 'show' );
+                       $this->dieWithError( 'apierror-show' );
                }
                if ( isset( $show['hidden'] ) || isset( $show['!hidden'] ) || isset( $prop['hidden'] ) ) {
                        $this->addOption( 'STRAIGHT_JOIN' );
index 4865ad5..02961aa 100644 (file)
@@ -65,7 +65,7 @@ class ApiQueryCategoryMembers extends ApiQueryGeneratorBase {
 
                $categoryTitle = $this->getTitleOrPageId( $params )->getTitle();
                if ( $categoryTitle->getNamespace() != NS_CATEGORY ) {
-                       $this->dieUsage( 'The category name you entered is not valid', 'invalidcategory' );
+                       $this->dieWithError( 'apierror-invalidcategory' );
                }
 
                $prop = array_flip( $params['prop'] );
@@ -153,7 +153,8 @@ class ApiQueryCategoryMembers extends ApiQueryGeneratorBase {
                                        $startsortkey = Collation::singleton()->getSortKey( $params['startsortkeyprefix'] );
                                } elseif ( $params['starthexsortkey'] !== null ) {
                                        if ( !$this->validateHexSortkey( $params['starthexsortkey'] ) ) {
-                                               $this->dieUsage( 'The starthexsortkey provided is not valid', 'bad_starthexsortkey' );
+                                               $encParamName = $this->encodeParamName( 'starthexsortkey' );
+                                               $this->dieWithError( [ 'apierror-badparameter', $encParamName ], "badvalue_$encParamName" );
                                        }
                                        $startsortkey = hex2bin( $params['starthexsortkey'] );
                                } else {
@@ -163,7 +164,8 @@ class ApiQueryCategoryMembers extends ApiQueryGeneratorBase {
                                        $endsortkey = Collation::singleton()->getSortKey( $params['endsortkeyprefix'] );
                                } elseif ( $params['endhexsortkey'] !== null ) {
                                        if ( !$this->validateHexSortkey( $params['endhexsortkey'] ) ) {
-                                               $this->dieUsage( 'The endhexsortkey provided is not valid', 'bad_endhexsortkey' );
+                                               $encParamName = $this->encodeParamName( 'endhexsortkey' );
+                                               $this->dieWithError( [ 'apierror-badparameter', $encParamName ], "badvalue_$encParamName" );
                                        }
                                        $endsortkey = hex2bin( $params['endhexsortkey'] );
                                } else {
index cfd0653..d0b8214 100644 (file)
@@ -39,12 +39,7 @@ class ApiQueryDeletedRevisions extends ApiQueryRevisionsBase {
        protected function run( ApiPageSet $resultPageSet = null ) {
                $user = $this->getUser();
                // Before doing anything at all, let's check permissions
-               if ( !$user->isAllowed( 'deletedhistory' ) ) {
-                       $this->dieUsage(
-                               'You don\'t have permission to view deleted revision information',
-                               'permissiondenied'
-                       );
-               }
+               $this->checkUserRightsAny( 'deletedhistory' );
 
                $pageSet = $this->getPageSet();
                $pageMap = $pageSet->getGoodAndMissingTitlesByNamespace();
@@ -63,9 +58,7 @@ class ApiQueryDeletedRevisions extends ApiQueryRevisionsBase {
 
                $db = $this->getDB();
 
-               if ( !is_null( $params['user'] ) && !is_null( $params['excludeuser'] ) ) {
-                       $this->dieUsage( 'user and excludeuser cannot be used together', 'badparams' );
-               }
+               $this->requireMaxOneParameter( $params, 'user', 'excludeuser' );
 
                $this->addTables( 'archive' );
                if ( $resultPageSet === null ) {
@@ -106,12 +99,7 @@ class ApiQueryDeletedRevisions extends ApiQueryRevisionsBase {
                        $this->addFields( [ 'ar_text', 'ar_flags', 'old_text', 'old_flags' ] );
 
                        // This also means stricter restrictions
-                       if ( !$user->isAllowedAny( 'undelete', 'deletedtext' ) ) {
-                               $this->dieUsage(
-                                       'You don\'t have permission to view deleted revision content',
-                                       'permissiondenied'
-                               );
-                       }
+                       $this->checkUserRightsAny( [ 'deletedtext', 'undelete' ] );
                }
 
                $dir = $params['dir'];
index d58efa1..6a259cd 100644 (file)
@@ -37,21 +37,12 @@ class ApiQueryDeletedrevs extends ApiQueryBase {
        }
 
        public function execute() {
-               $user = $this->getUser();
                // Before doing anything at all, let's check permissions
-               if ( !$user->isAllowed( 'deletedhistory' ) ) {
-                       $this->dieUsage(
-                               'You don\'t have permission to view deleted revision information',
-                               'permissiondenied'
-                       );
-               }
+               $this->checkUserRightsAny( 'deletedhistory' );
 
-               $this->setWarning(
-                       'list=deletedrevs has been deprecated. Please use prop=deletedrevisions or ' .
-                       'list=alldeletedrevisions instead.'
-               );
-               $this->logFeatureUsage( 'action=query&list=deletedrevs' );
+               $this->addDeprecation( 'apiwarn-deprecation-deletedrevs', 'action=query&list=deletedrevs' );
 
+               $user = $this->getUser();
                $db = $this->getDB();
                $params = $this->extractRequestParams( false );
                $prop = array_flip( $params['prop'] );
@@ -70,9 +61,6 @@ class ApiQueryDeletedrevs extends ApiQueryBase {
 
                if ( isset( $prop['token'] ) ) {
                        $p = $this->getModulePrefix();
-                       $this->setWarning(
-                               "{$p}prop=token has been deprecated. Please use action=query&meta=tokens instead."
-                       );
                }
 
                // If we're in a mode that breaks the same-origin policy, no tokens can
@@ -105,19 +93,19 @@ class ApiQueryDeletedrevs extends ApiQueryBase {
                        // Ignore namespace and unique due to inability to know whether they were purposely set
                        foreach ( [ 'from', 'to', 'prefix', /*'namespace', 'unique'*/ ] as $p ) {
                                if ( !is_null( $params[$p] ) ) {
-                                       $this->dieUsage( "The '{$p}' parameter cannot be used in modes 1 or 2", 'badparams' );
+                                       $this->dieWithError( [ 'apierror-deletedrevs-param-not-1-2', $p ], 'badparams' );
                                }
                        }
                } else {
                        foreach ( [ 'start', 'end' ] as $p ) {
                                if ( !is_null( $params[$p] ) ) {
-                                       $this->dieUsage( "The {$p} parameter cannot be used in mode 3", 'badparams' );
+                                       $this->dieWithError( [ 'apierror-deletedrevs-param-not-3', $p ], 'badparams' );
                                }
                        }
                }
 
                if ( !is_null( $params['user'] ) && !is_null( $params['excludeuser'] ) ) {
-                       $this->dieUsage( 'user and excludeuser cannot be used together', 'badparams' );
+                       $this->dieWithError( 'user and excludeuser cannot be used together', 'badparams' );
                }
 
                $this->addTables( 'archive' );
@@ -162,12 +150,7 @@ class ApiQueryDeletedrevs extends ApiQueryBase {
                        $this->addFields( [ 'ar_text', 'ar_flags', 'ar_text_id', 'old_text', 'old_flags' ] );
 
                        // This also means stricter restrictions
-                       if ( !$user->isAllowedAny( 'undelete', 'deletedtext' ) ) {
-                               $this->dieUsage(
-                                       'You don\'t have permission to view deleted revision content',
-                                       'permissiondenied'
-                               );
-                       }
+                       $this->checkUserRightsAny( [ 'deletedtext', 'undelete' ] );
                }
                // Check limits
                $userMax = $fld_content ? ApiBase::LIMIT_SML1 : ApiBase::LIMIT_BIG1;
index e1c97e1..9476066 100644 (file)
@@ -37,7 +37,7 @@
 class ApiQueryDisabled extends ApiQueryBase {
 
        public function execute() {
-               $this->setWarning( "The \"{$this->getModuleName()}\" module has been disabled." );
+               $this->addWarning( [ 'apierror-moduledisabled', $this->getModuleName() ] );
        }
 
        public function getAllowedParams() {
index 03be491..116dbb3 100644 (file)
@@ -38,15 +38,10 @@ class ApiQueryFilearchive extends ApiQueryBase {
        }
 
        public function execute() {
-               $user = $this->getUser();
                // Before doing anything at all, let's check permissions
-               if ( !$user->isAllowed( 'deletedhistory' ) ) {
-                       $this->dieUsage(
-                               'You don\'t have permission to view deleted file information',
-                               'permissiondenied'
-                       );
-               }
+               $this->checkUserRightsAny( 'deletedhistory' );
 
+               $user = $this->getUser();
                $db = $this->getDB();
 
                $params = $this->extractRequestParams();
@@ -112,13 +107,13 @@ class ApiQueryFilearchive extends ApiQueryBase {
                        if ( $sha1Set ) {
                                $sha1 = strtolower( $params['sha1'] );
                                if ( !$this->validateSha1Hash( $sha1 ) ) {
-                                       $this->dieUsage( 'The SHA1 hash provided is not valid', 'invalidsha1hash' );
+                                       $this->dieWithError( 'apierror-invalidsha1hash' );
                                }
                                $sha1 = Wikimedia\base_convert( $sha1, 16, 36, 31 );
                        } elseif ( $sha1base36Set ) {
                                $sha1 = strtolower( $params['sha1base36'] );
                                if ( !$this->validateSha1Base36Hash( $sha1 ) ) {
-                                       $this->dieUsage( 'The SHA1Base36 hash provided is not valid', 'invalidsha1base36hash' );
+                                       $this->dieWithError( 'apierror-invalidsha1base36hash' );
                                }
                        }
                        if ( $sha1 ) {
index 7568107..6e2fb67 100644 (file)
@@ -51,7 +51,14 @@ class ApiQueryIWBacklinks extends ApiQueryGeneratorBase {
                $params = $this->extractRequestParams();
 
                if ( isset( $params['title'] ) && !isset( $params['prefix'] ) ) {
-                       $this->dieUsageMsg( [ 'missingparam', 'prefix' ] );
+                       $this->dieWithError(
+                               [
+                                       'apierror-invalidparammix-mustusewith',
+                                       $this->encodeParamName( 'title' ),
+                                       $this->encodeParamName( 'prefix' ),
+                               ],
+                               'invalidparammix'
+                       );
                }
 
                if ( !is_null( $params['continue'] ) ) {
index 6d9c2ca..cfd990b 100644 (file)
@@ -45,7 +45,14 @@ class ApiQueryIWLinks extends ApiQueryBase {
                $prop = array_flip( (array)$params['prop'] );
 
                if ( isset( $params['title'] ) && !isset( $params['prefix'] ) ) {
-                       $this->dieUsageMsg( [ 'missingparam', 'prefix' ] );
+                       $this->dieWithError(
+                               [
+                                       'apierror-invalidparammix-mustusewith',
+                                       $this->encodeParamName( 'title' ),
+                                       $this->encodeParamName( 'prefix' ),
+                               ],
+                               'invalidparammix'
+                       );
                }
 
                // Handle deprecated param
index d1fcfa3..0bbfad3 100644 (file)
@@ -280,8 +280,7 @@ class ApiQueryImageInfo extends ApiQueryBase {
 
                $h = $image->getHandler();
                if ( !$h ) {
-                       $this->setWarning( 'Could not create thumbnail because ' .
-                               $image->getName() . ' does not have an associated image handler' );
+                       $this->addWarning( [ 'apiwarn-nothumb-noimagehandler', wfEscapeWikiText( $image->getName() ) ] );
 
                        return $thumbParams;
                }
@@ -292,23 +291,24 @@ class ApiQueryImageInfo extends ApiQueryBase {
                        // we could still render the image using width and height parameters,
                        // and this type of thing could happen between different versions of
                        // handlers.
-                       $this->setWarning( "Could not parse {$p}urlparam for " . $image->getName()
-                               . '. Using only width and height' );
+                       $this->addWarning( [ 'apiwarn-badurlparam', $p, wfEscapeWikiText( $image->getName() ) ] );
                        $this->checkParameterNormalise( $image, $thumbParams );
                        return $thumbParams;
                }
 
                if ( isset( $paramList['width'] ) && isset( $thumbParams['width'] ) ) {
                        if ( intval( $paramList['width'] ) != intval( $thumbParams['width'] ) ) {
-                               $this->setWarning( "Ignoring width value set in {$p}urlparam ({$paramList['width']}) "
-                                       . "in favor of width value derived from {$p}urlwidth/{$p}urlheight "
-                                       . "({$thumbParams['width']})" );
+                               $this->addWarning(
+                                       [ 'apiwarn-urlparamwidth', $p, $paramList['width'], $thumbParams['width'] ]
+                               );
                        }
                }
 
                foreach ( $paramList as $name => $value ) {
                        if ( !$h->validateParam( $name, $value ) ) {
-                               $this->dieUsage( "Invalid value for {$p}urlparam ($name=$value)", 'urlparam' );
+                               $this->dieWithError(
+                                       [ 'apierror-invalidurlparam', $p, wfEscapeWikiText( $name ), wfEscapeWikiText( $value ) ]
+                               );
                        }
                }
 
@@ -337,8 +337,7 @@ class ApiQueryImageInfo extends ApiQueryBase {
                // in the actual normalised version, only if we can actually normalise them,
                // so we use the functions scope to throw away the normalisations.
                if ( !$h->normaliseParams( $image, $finalParams ) ) {
-                       $this->dieUsage( 'Could not normalise image parameters for ' .
-                               $image->getName(), 'urlparamnormal' );
+                       $this->dieWithError( [ 'apierror-urlparamnormal', wfEscapeWikiText( $image->getName() ) ] );
                }
        }
 
index e04d8c8..ae6f5bf 100644 (file)
@@ -90,7 +90,7 @@ class ApiQueryImages extends ApiQueryGeneratorBase {
                        foreach ( $params['images'] as $img ) {
                                $title = Title::newFromText( $img );
                                if ( !$title || $title->getNamespace() != NS_FILE ) {
-                                       $this->setWarning( "\"$img\" is not a file" );
+                                       $this->addWarning( [ 'apiwarn-notfile', wfEscapeWikiText( $img ) ] );
                                } else {
                                        $images[] = $title->getDBkey();
                                }
index d287020..fd65038 100644 (file)
@@ -427,7 +427,7 @@ class ApiQueryInfo extends ApiQueryBase {
                        foreach ( $this->params['token'] as $t ) {
                                $val = call_user_func( $tokenFunctions[$t], $pageid, $title );
                                if ( $val === false ) {
-                                       $this->setWarning( "Action '$t' is not allowed for the current user" );
+                                       $this->addWarning( [ 'apiwarn-tokennotallowed', $t ] );
                                } else {
                                        $pageInfo[$t . 'token'] = $val;
                                }
index a6153de..8d5b5f3 100644 (file)
@@ -51,7 +51,14 @@ class ApiQueryLangBacklinks extends ApiQueryGeneratorBase {
                $params = $this->extractRequestParams();
 
                if ( isset( $params['title'] ) && !isset( $params['lang'] ) ) {
-                       $this->dieUsageMsg( [ 'missingparam', 'lang' ] );
+                       $this->dieWithError(
+                               [
+                                       'apierror-invalidparammix-mustusewith',
+                                       $this->encodeParamName( 'title' ),
+                                       $this->encodeParamName( 'lang' )
+                               ],
+                               'nolang'
+                       );
                }
 
                if ( !is_null( $params['continue'] ) ) {
index 67f2c9e..55e3c85 100644 (file)
@@ -44,7 +44,14 @@ class ApiQueryLangLinks extends ApiQueryBase {
                $prop = array_flip( (array)$params['prop'] );
 
                if ( isset( $params['title'] ) && !isset( $params['lang'] ) ) {
-                       $this->dieUsageMsg( [ 'missingparam', 'lang' ] );
+                       $this->dieWithError(
+                               [
+                                       'apierror-invalidparammix-mustusewith',
+                                       $this->encodeParamName( 'title' ),
+                                       $this->encodeParamName( 'lang' ),
+                               ],
+                               'invalidparammix'
+                       );
                }
 
                // Handle deprecated param
index 6e5239f..e9ae132 100644 (file)
@@ -94,7 +94,7 @@ class ApiQueryLinks extends ApiQueryGeneratorBase {
                        foreach ( $params[$this->titlesParam] as $t ) {
                                $title = Title::newFromText( $t );
                                if ( !$title ) {
-                                       $this->setWarning( "\"$t\" is not a valid title" );
+                                       $this->addWarning( [ 'apiwarn-invalidtitle', wfEscapeWikiText( $t ) ] );
                                } else {
                                        $lb->addObj( $title );
                                }
index 122594d..2dcd0b4 100644 (file)
@@ -121,10 +121,10 @@ class ApiQueryLogEvents extends ApiQueryBase {
                        }
 
                        if ( !$valid ) {
-                               $valueName = $this->encodeParamName( 'action' );
-                               $this->dieUsage(
-                                       "Unrecognized value for parameter '$valueName': {$logAction}",
-                                       "unknown_$valueName"
+                               $encParamName = $this->encodeParamName( 'action' );
+                               $this->dieWithError(
+                                       [ 'apierror-unrecognizedvalue', $encParamName, wfEscapeWikiText( $logAction ) ],
+                                       "unknown_$encParamName"
                                );
                        }
 
@@ -173,7 +173,7 @@ class ApiQueryLogEvents extends ApiQueryBase {
                if ( !is_null( $title ) ) {
                        $titleObj = Title::newFromText( $title );
                        if ( is_null( $titleObj ) ) {
-                               $this->dieUsage( "Bad title value '$title'", 'param_title' );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $title ) ] );
                        }
                        $this->addWhereFld( 'log_namespace', $titleObj->getNamespace() );
                        $this->addWhereFld( 'log_title', $titleObj->getDBkey() );
@@ -187,12 +187,12 @@ class ApiQueryLogEvents extends ApiQueryBase {
 
                if ( !is_null( $prefix ) ) {
                        if ( $this->getConfig()->get( 'MiserMode' ) ) {
-                               $this->dieUsage( 'Prefix search disabled in Miser Mode', 'prefixsearchdisabled' );
+                               $this->dieWithError( 'apierror-prefixsearchdisabled' );
                        }
 
                        $title = Title::newFromText( $prefix );
                        if ( is_null( $title ) ) {
-                               $this->dieUsage( "Bad title value '$prefix'", 'param_prefix' );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $prefix ) ] );
                        }
                        $this->addWhereFld( 'log_namespace', $title->getNamespace() );
                        $this->addWhere( 'log_title ' . $db->buildLike( $title->getDBkey(), $db->anyString() ) );
index 0c70a8a..1324f2f 100644 (file)
@@ -36,7 +36,7 @@ class ApiQueryMyStashedFiles extends ApiQueryBase {
                $user = $this->getUser();
 
                if ( $user->isAnon() ) {
-                       $this->dieUsage( 'The upload stash is only available to logged-in users.', 'stashnotloggedin' );
+                       $this->dieWithError( 'apierror-mustbeloggedin-uploadstash', 'stashnotloggedin' );
                }
 
                // Note: If user is logged in but cannot upload, they can still see
index 9ba757c..908cdee 100644 (file)
@@ -62,7 +62,7 @@ class ApiQueryQueryPage extends ApiQueryGeneratorBase {
                /** @var $qp QueryPage */
                $qp = new $this->qpMap[$params['page']]();
                if ( !$qp->userCanExecute( $this->getUser() ) ) {
-                       $this->dieUsageMsg( 'specialpage-cantexecute' );
+                       $this->dieWithError( 'apierror-specialpage-cantexecute' );
                }
 
                $r = [ 'name' => $params['page'] ];
index 8b11dc2..8d14927 100644 (file)
@@ -195,7 +195,7 @@ class ApiQueryRecentChanges extends ApiQueryGeneratorBase {
                                || ( isset( $show['patrolled'] ) && isset( $show['unpatrolled'] ) )
                                || ( isset( $show['!patrolled'] ) && isset( $show['unpatrolled'] ) )
                        ) {
-                               $this->dieUsageMsg( 'show' );
+                               $this->dieWithError( 'apierror-show' );
                        }
 
                        // Check permissions
@@ -204,10 +204,7 @@ class ApiQueryRecentChanges extends ApiQueryGeneratorBase {
                                || isset( $show['unpatrolled'] )
                        ) {
                                if ( !$user->useRCPatrol() && !$user->useNPPatrol() ) {
-                                       $this->dieUsage(
-                                               'You need patrol or patrolmarks permission to request the patrolled flag',
-                                               'permissiondenied'
-                                       );
+                                       $this->dieWithError( 'apierror-permissiondenied-patrolflag', 'permissiondenied' );
                                }
                        }
 
@@ -239,9 +236,7 @@ class ApiQueryRecentChanges extends ApiQueryGeneratorBase {
                        );
                }
 
-               if ( !is_null( $params['user'] ) && !is_null( $params['excludeuser'] ) ) {
-                       $this->dieUsage( 'user and excludeuser cannot be used together', 'user-excludeuser' );
-               }
+               $this->requireMaxOneParameter( $params, 'user', 'excludeuser' );
 
                if ( !is_null( $params['user'] ) ) {
                        $this->addWhereFld( 'rc_user_text', $params['user'] );
@@ -274,10 +269,7 @@ class ApiQueryRecentChanges extends ApiQueryGeneratorBase {
                        $this->initProperties( $prop );
 
                        if ( $this->fld_patrolled && !$user->useRCPatrol() && !$user->useNPPatrol() ) {
-                               $this->dieUsage(
-                                       'You need patrol or patrolmarks permission to request the patrolled flag',
-                                       'permissiondenied'
-                               );
+                               $this->dieWithError( 'apierror-permissiondenied-patrolflag', 'permissiondenied' );
                        }
 
                        /* Add fields to our query if they are specified as a needed parameter. */
@@ -571,7 +563,7 @@ class ApiQueryRecentChanges extends ApiQueryGeneratorBase {
                                $val = call_user_func( $tokenFunctions[$t], $row->rc_cur_id,
                                        $title, RecentChange::newFromRow( $row ) );
                                if ( $val === false ) {
-                                       $this->setWarning( "Action '$t' is not allowed for the current user" );
+                                       $this->addWarning( [ 'apiwarn-tokennotallowed', $t ] );
                                } else {
                                        $vals[$t . 'token'] = $val;
                                }
index 3259927..48f6046 100644 (file)
@@ -110,19 +110,14 @@ class ApiQueryRevisions extends ApiQueryRevisionsBase {
                }
 
                if ( $revCount > 0 && $enumRevMode ) {
-                       $this->dieUsage(
-                               'The revids= parameter may not be used with the list options ' .
-                                       '(limit, startid, endid, dirNewer, start, end).',
-                               'revids'
+                       $this->dieWithError(
+                               [ 'apierror-revisions-nolist', $this->getModulePrefix() ], 'invalidparammix'
                        );
                }
 
                if ( $pageCount > 1 && $enumRevMode ) {
-                       $this->dieUsage(
-                               'titles, pageids or a generator was used to supply multiple pages, ' .
-                                       'but the limit, startid, endid, dirNewer, user, excludeuser, start ' .
-                                       'and end parameters may only be used on a single page.',
-                               'multpages'
+                       $this->dieWithError(
+                               [ 'apierror-revisions-singlepage', $this->getModulePrefix() ], 'invalidparammix'
                        );
                }
 
@@ -170,14 +165,19 @@ class ApiQueryRevisions extends ApiQueryRevisionsBase {
                if ( $this->fetchContent ) {
                        // For each page we will request, the user must have read rights for that page
                        $user = $this->getUser();
+                       $status = Status::newGood();
                        /** @var $title Title */
                        foreach ( $pageSet->getGoodTitles() as $title ) {
                                if ( !$title->userCan( 'read', $user ) ) {
-                                       $this->dieUsage(
-                                               'The current user is not allowed to read ' . $title->getPrefixedText(),
-                                               'accessdenied' );
+                                       $status->fatal( ApiMessage::create(
+                                               [ 'apierror-cannotviewtitle', wfEscapeWikiText( $title->getPrefixedText() ) ],
+                                               'accessdenied'
+                                       ) );
                                }
                        }
+                       if ( !$status->isGood() ) {
+                               $this->dieStatus( $status );
+                       }
 
                        $this->addTables( 'text' );
                        $this->addJoinConds(
@@ -201,17 +201,9 @@ class ApiQueryRevisions extends ApiQueryRevisionsBase {
                        //  page_timestamp or usertext_timestamp if we have an IP rvuser
 
                        // This is mostly to prevent parameter errors (and optimize SQL?)
-                       if ( $params['startid'] !== null && $params['start'] !== null ) {
-                               $this->dieUsage( 'start and startid cannot be used together', 'badparams' );
-                       }
-
-                       if ( $params['endid'] !== null && $params['end'] !== null ) {
-                               $this->dieUsage( 'end and endid cannot be used together', 'badparams' );
-                       }
-
-                       if ( $params['user'] !== null && $params['excludeuser'] !== null ) {
-                               $this->dieUsage( 'user and excludeuser cannot be used together', 'badparams' );
-                       }
+                       $this->requireMaxOneParameter( $params, 'startid', 'start' );
+                       $this->requireMaxOneParameter( $params, 'endid', 'end' );
+                       $this->requireMaxOneParameter( $params, 'user', 'excludeuser' );
 
                        if ( $params['continue'] !== null ) {
                                $cont = explode( '|', $params['continue'] );
@@ -344,7 +336,7 @@ class ApiQueryRevisions extends ApiQueryRevisionsBase {
                                        foreach ( $this->token as $t ) {
                                                $val = call_user_func( $tokenFunctions[$t], $title->getArticleID(), $title, $revision );
                                                if ( $val === false ) {
-                                                       $this->setWarning( "Action '$t' is not allowed for the current user" );
+                                                       $this->addWarning( [ 'apiwarn-tokennotallowed', $t ] );
                                                } else {
                                                        $rev[$t . 'token'] = $val;
                                                }
index 266d699..696ec87 100644 (file)
@@ -70,10 +70,7 @@ abstract class ApiQueryRevisionsBase extends ApiQueryGeneratorBase {
                                && $params['diffto'] != 'prev' && $params['diffto'] != 'next'
                        ) {
                                $p = $this->getModulePrefix();
-                               $this->dieUsage(
-                                       "{$p}diffto must be set to a non-negative number, \"prev\", \"next\" or \"cur\"",
-                                       'diffto'
-                               );
+                               $this->dieWithError( [ 'apierror-baddiffto', $p ], 'diffto' );
                        }
                        // Check whether the revision exists and is readable,
                        // DifferenceEngine returns a rather ambiguous empty
@@ -81,10 +78,10 @@ abstract class ApiQueryRevisionsBase extends ApiQueryGeneratorBase {
                        if ( $params['diffto'] != 0 ) {
                                $difftoRev = Revision::newFromId( $params['diffto'] );
                                if ( !$difftoRev ) {
-                                       $this->dieUsageMsg( [ 'nosuchrevid', $params['diffto'] ] );
+                                       $this->dieWithError( [ 'apierror-nosuchrevid', $params['diffto'] ] );
                                }
                                if ( !$difftoRev->userCan( Revision::DELETED_TEXT, $this->getUser() ) ) {
-                                       $this->setWarning( "Couldn't diff to r{$difftoRev->getId()}: content is hidden" );
+                                       $this->addWarning( [ 'apiwarn-difftohidden', $difftoRev->getId() ] );
                                        $params['diffto'] = null;
                                }
                        }
@@ -262,8 +259,12 @@ abstract class ApiQueryRevisionsBase extends ApiQueryGeneratorBase {
                        if ( $content && $this->section !== false ) {
                                $content = $content->getSection( $this->section, false );
                                if ( !$content ) {
-                                       $this->dieUsage(
-                                               "There is no section {$this->section} in r" . $revision->getId(),
+                                       $this->dieWithError(
+                                               [
+                                                       'apierror-nosuchsection-what',
+                                                       wfEscapeWikiText( $this->section ),
+                                                       $this->msg( 'revid', $revision->getId() )
+                                               ],
                                                'nosuchsection'
                                        );
                                }
@@ -294,9 +295,14 @@ abstract class ApiQueryRevisionsBase extends ApiQueryGeneratorBase {
                                        $vals['parsetree'] = $xml;
                                } else {
                                        $vals['badcontentformatforparsetree'] = true;
-                                       $this->setWarning( 'Conversion to XML is supported for wikitext only, ' .
-                                               $title->getPrefixedDBkey() .
-                                               ' uses content model ' . $content->getModel() );
+                                       $this->addWarning(
+                                               [
+                                                       'apierror-parsetree-notwikitext-title',
+                                                       wfEscapeWikiText( $title->getPrefixedText() ),
+                                                       $content->getModel()
+                                               ],
+                                               'parsetree-notwikitext'
+                                       );
                                }
                        }
                }
@@ -315,9 +321,11 @@ abstract class ApiQueryRevisionsBase extends ApiQueryGeneratorBase {
                                                ParserOptions::newFromContext( $this->getContext() )
                                        );
                                } else {
-                                       $this->setWarning( 'Template expansion is supported for wikitext only, ' .
-                                               $title->getPrefixedDBkey() .
-                                               ' uses content model ' . $content->getModel() );
+                                       $this->addWarning( [
+                                               'apierror-templateexpansion-notwikitext',
+                                               wfEscapeWikiText( $title->getPrefixedText() ),
+                                               $content->getModel()
+                                       ] );
                                        $vals['badcontentformat'] = true;
                                        $text = false;
                                }
@@ -336,9 +344,8 @@ abstract class ApiQueryRevisionsBase extends ApiQueryGeneratorBase {
                                $model = $content->getModel();
 
                                if ( !$content->isSupportedFormat( $format ) ) {
-                                       $name = $title->getPrefixedDBkey();
-                                       $this->setWarning( "The requested format {$this->contentFormat} is not " .
-                                               "supported for content model $model used by $name" );
+                                       $name = wfEscapeWikiText( $title->getPrefixedText() );
+                                       $this->addWarning( [ 'apierror-badformat', $this->contentFormat, $model, $name ] );
                                        $vals['badcontentformat'] = true;
                                        $text = false;
                                } else {
@@ -370,9 +377,8 @@ abstract class ApiQueryRevisionsBase extends ApiQueryGeneratorBase {
                                        if ( $this->contentFormat
                                                && !ContentHandler::getForModelID( $model )->isSupportedFormat( $this->contentFormat )
                                        ) {
-                                               $name = $title->getPrefixedDBkey();
-                                               $this->setWarning( "The requested format {$this->contentFormat} is not " .
-                                                       "supported for content model $model used by $name" );
+                                               $name = wfEscapeWikiText( $title->getPrefixedText() );
+                                               $this->addWarning( [ 'apierror-badformat', $this->contentFormat, $model, $name ] );
                                                $vals['diff']['badcontentformat'] = true;
                                                $engine = null;
                                        } else {
index 9962d5e..64bc43f 100644 (file)
@@ -64,12 +64,14 @@ class ApiQuerySearch extends ApiQueryGeneratorBase {
 
                // Deprecated parameters
                if ( isset( $prop['hasrelated'] ) ) {
-                       $this->logFeatureUsage( 'action=search&srprop=hasrelated' );
-                       $this->setWarning( 'srprop=hasrelated has been deprecated' );
+                       $this->addDeprecation(
+                               [ 'apiwarn-deprecation-parameter', 'srprop=hasrelated' ], 'action=search&srprop=hasrelated'
+                       );
                }
                if ( isset( $prop['score'] ) ) {
-                       $this->logFeatureUsage( 'action=search&srprop=score' );
-                       $this->setWarning( 'srprop=score has been deprecated' );
+                       $this->addDeprecation(
+                               [ 'apiwarn-deprecation-parameter', 'srprop=score' ], 'action=search&srprop=score'
+                       );
                }
 
                // Create search engine instance and set options
@@ -122,10 +124,10 @@ class ApiQuerySearch extends ApiQueryGeneratorBase {
                                        $status
                                );
                        } else {
-                               $this->dieUsage( $status->getWikiText( false, false, 'en' ), 'search-error' );
+                               $this->dieStatus( $status );
                        }
                } elseif ( is_null( $matches ) ) {
-                       $this->dieUsage( "{$what} search is disabled", "search-{$what}-disabled" );
+                       $this->dieWithError( [ 'apierror-searchdisabled', $what ], "search-{$what}-disabled" );
                }
 
                if ( $resultPageSet === null ) {
index 19e0c93..6fc6aa3 100644 (file)
@@ -447,10 +447,7 @@ class ApiQuerySiteinfo extends ApiQueryBase {
                $showHostnames = $this->getConfig()->get( 'ShowHostnames' );
                if ( $includeAll ) {
                        if ( !$showHostnames ) {
-                               $this->dieUsage(
-                                       'Cannot view all servers info unless $wgShowHostnames is true',
-                                       'includeAllDenied'
-                               );
+                               $this->dieWithError( 'apierror-siteinfo-includealldenied', 'includeAllDenied' );
                        }
 
                        $lags = $lb->getLagTimes();
index b039a1e..981cb09 100644 (file)
@@ -33,7 +33,7 @@ class ApiQueryStashImageInfo extends ApiQueryImageInfo {
 
        public function execute() {
                if ( !$this->getUser()->isLoggedIn() ) {
-                       $this->dieUsage( 'You must be logged-in to have an upload stash', 'notloggedin' );
+                       $this->dieWithError( 'apierror-mustbeloggedin-uploadstash', 'notloggedin' );
                }
 
                $params = $this->extractRequestParams();
@@ -45,9 +45,7 @@ class ApiQueryStashImageInfo extends ApiQueryImageInfo {
 
                $result = $this->getResult();
 
-               if ( !$params['filekey'] && !$params['sessionkey'] ) {
-                       $this->dieUsage( 'One of filekey or sessionkey must be supplied', 'nofilekey' );
-               }
+               $this->requireAtLeastOneParameter( $params, 'filekey', 'sessionkey' );
 
                // Alias sessionkey to filekey, but give an existing filekey precedence.
                if ( !$params['filekey'] && $params['sessionkey'] ) {
@@ -65,10 +63,11 @@ class ApiQueryStashImageInfo extends ApiQueryImageInfo {
                                $result->addIndexedTagName( [ 'query', $this->getModuleName() ], $modulePrefix );
                        }
                // @todo Update exception handling here to understand current getFile exceptions
+               // @todo Internationalize the exceptions
                } catch ( UploadStashFileNotFoundException $e ) {
-                       $this->dieUsage( 'File not found: ' . $e->getMessage(), 'invalidsessiondata' );
+                       $this->dieWithError( [ 'apierror-stashedfilenotfound', wfEscapeWikiText( $e->getMessage() ) ] );
                } catch ( UploadStashBadPathException $e ) {
-                       $this->dieUsage( 'Bad path: ' . $e->getMessage(), 'invalidsessiondata' );
+                       $this->dieWithError( [ 'apierror-stashpathinvalid', wfEscapeWikiText( $e->getMessage() ) ] );
                }
        }
 
index de5a377..5b700db 100644 (file)
@@ -40,7 +40,7 @@ class ApiQueryTokens extends ApiQueryBase {
                ];
 
                if ( $this->lacksSameOriginSecurity() ) {
-                       $this->setWarning( 'Tokens may not be obtained when the same-origin policy is not applied' );
+                       $this->addWarning( [ 'apiwarn-tokens-origin' ] );
                        return;
                }
 
index b85bec4..b6d871b 100644 (file)
@@ -78,11 +78,17 @@ class ApiQueryContributions extends ApiQueryBase {
                                $this->params['user'] = [ $this->params['user'] ];
                        }
                        if ( !count( $this->params['user'] ) ) {
-                               $this->dieUsage( 'User parameter may not be empty.', 'param_user' );
+                               $encParamName = $this->encodeParamName( 'user' );
+                               $this->dieWithError(
+                                       [ 'apierror-paramempty', $encParamName ], "paramempty_$encParamName"
+                               );
                        }
                        foreach ( $this->params['user'] as $u ) {
                                if ( is_null( $u ) || $u === '' ) {
-                                       $this->dieUsage( 'User parameter may not be empty', 'param_user' );
+                                       $encParamName = $this->encodeParamName( 'user' );
+                                       $this->dieWithError(
+                                               [ 'apierror-paramempty', $encParamName ], "paramempty_$encParamName"
+                                       );
                                }
 
                                if ( User::isIP( $u ) ) {
@@ -91,7 +97,10 @@ class ApiQueryContributions extends ApiQueryBase {
                                } else {
                                        $name = User::getCanonicalName( $u, 'valid' );
                                        if ( $name === false ) {
-                                               $this->dieUsage( "User name {$u} is not valid", 'param_user' );
+                                               $encParamName = $this->encodeParamName( 'user' );
+                                               $this->dieWithError(
+                                                       [ 'apierror-baduser', $encParamName, wfEscapeWikiText( $u ) ], "baduser_$encParamName"
+                                               );
                                        }
                                        $this->usernames[] = $name;
                                }
@@ -254,7 +263,7 @@ class ApiQueryContributions extends ApiQueryBase {
                                || ( isset( $show['top'] ) && isset( $show['!top'] ) )
                                || ( isset( $show['new'] ) && isset( $show['!new'] ) )
                        ) {
-                               $this->dieUsageMsg( 'show' );
+                               $this->dieWithError( 'apierror-show' );
                        }
 
                        $this->addWhereIf( 'rev_minor_edit = 0', isset( $show['!minor'] ) );
@@ -285,10 +294,7 @@ class ApiQueryContributions extends ApiQueryBase {
                        $this->fld_patrolled
                ) {
                        if ( !$user->useRCPatrol() && !$user->useNPPatrol() ) {
-                               $this->dieUsage(
-                                       'You need the patrol right to request the patrolled flag',
-                                       'permissiondenied'
-                               );
+                               $this->dieWithError( 'apierror-permissiondenied-patrolflag', 'permissiondenied' );
                        }
 
                        // Use a redundant join condition on both
index d3cd0c4..3b60478 100644 (file)
@@ -170,8 +170,13 @@ class ApiQueryUserInfo extends ApiQueryBase {
 
                if ( isset( $this->prop['preferencestoken'] ) ) {
                        $p = $this->getModulePrefix();
-                       $this->setWarning(
-                               "{$p}prop=preferencestoken has been deprecated. Please use action=query&meta=tokens instead."
+                       $this->addDeprecation(
+                               [
+                                       'apiwarn-deprecation-withreplacement',
+                                       "{$p}prop=preferencestoken",
+                                       'action=query&meta=tokens',
+                               ],
+                               "meta=userinfo&{$p}prop=preferencestoken"
                        );
                }
                if ( isset( $this->prop['preferencestoken'] ) &&
index 9b45b91..65d3797 100644 (file)
@@ -226,7 +226,7 @@ class ApiQueryUsers extends ApiQueryBase {
                                        foreach ( $params['token'] as $t ) {
                                                $val = call_user_func( $tokenFunctions[$t], $user );
                                                if ( $val === false ) {
-                                                       $this->setWarning( "Action '$t' is not allowed for the current user" );
+                                                       $this->addWarning( [ 'apiwarn-tokennotallowed', $t ] );
                                                } else {
                                                        $data[$name][$t . 'token'] = $val;
                                                }
@@ -253,7 +253,7 @@ class ApiQueryUsers extends ApiQueryBase {
                                                foreach ( $params['token'] as $t ) {
                                                        $val = call_user_func( $tokenFunctions[$t], $iwUser );
                                                        if ( $val === false ) {
-                                                               $this->setWarning( "Action '$t' is not allowed for the current user" );
+                                                               $this->addWarning( [ 'apiwarn-tokennotallowed', $t ] );
                                                        } else {
                                                                $data[$u][$t . 'token'] = $val;
                                                        }
index 42ea55d..6b5ceb7 100644 (file)
@@ -82,7 +82,7 @@ class ApiQueryWatchlist extends ApiQueryGeneratorBase {
 
                        if ( $this->fld_patrol ) {
                                if ( !$user->useRCPatrol() && !$user->useNPPatrol() ) {
-                                       $this->dieUsage( 'patrol property is not available', 'patrol' );
+                                       $this->dieWithError( 'apierror-permissiondenied-patrolflag', 'patrol' );
                                }
                        }
                }
@@ -134,7 +134,7 @@ class ApiQueryWatchlist extends ApiQueryGeneratorBase {
 
                        /* Check for conflicting parameters. */
                        if ( $this->showParamsConflicting( $show ) ) {
-                               $this->dieUsageMsg( 'show' );
+                               $this->dieWithError( 'apierror-show' );
                        }
 
                        // Check permissions.
@@ -142,10 +142,7 @@ class ApiQueryWatchlist extends ApiQueryGeneratorBase {
                                || isset( $show[WatchedItemQueryService::FILTER_NOT_PATROLLED] )
                        ) {
                                if ( !$user->useRCPatrol() && !$user->useNPPatrol() ) {
-                                       $this->dieUsage(
-                                               'You need the patrol right to request the patrolled flag',
-                                               'permissiondenied'
-                                       );
+                                       $this->dieWithError( 'apierror-permissiondenied-patrolflag', 'permissiondenied' );
                                }
                        }
 
@@ -160,9 +157,7 @@ class ApiQueryWatchlist extends ApiQueryGeneratorBase {
                        }
                }
 
-               if ( !is_null( $params['user'] ) && !is_null( $params['excludeuser'] ) ) {
-                       $this->dieUsage( 'user and excludeuser cannot be used together', 'user-excludeuser' );
-               }
+               $this->requireMaxOneParameter( $params, 'user', 'excludeuser' );
                if ( !is_null( $params['user'] ) ) {
                        $options['onlyByUser'] = $params['user'];
                }
index 806861e..a1078a5 100644 (file)
@@ -60,7 +60,7 @@ class ApiQueryWatchlistRaw extends ApiQueryGeneratorBase {
                if ( isset( $show[WatchedItemQueryService::FILTER_CHANGED] )
                        && isset( $show[WatchedItemQueryService::FILTER_NOT_CHANGED] )
                ) {
-                       $this->dieUsageMsg( 'show' );
+                       $this->dieWithError( 'apierror-show' );
                }
 
                $options = [];
index d72c8a4..359d045 100644 (file)
@@ -45,7 +45,7 @@ class ApiRemoveAuthenticationData extends ApiBase {
 
        public function execute() {
                if ( !$this->getUser()->isLoggedIn() ) {
-                       $this->dieUsage( 'Must be logged in to remove authentication data', 'notloggedin' );
+                       $this->dieWithError( 'apierror-mustbeloggedin-removeauth', 'notloggedin' );
                }
 
                $params = $this->extractRequestParams();
@@ -67,7 +67,7 @@ class ApiRemoveAuthenticationData extends ApiBase {
                        }
                );
                if ( count( $reqs ) !== 1 ) {
-                       $this->dieUsage( 'Failed to create change request', 'badrequest' );
+                       $this->dieWithError( 'apierror-changeauth-norequest', 'badrequest' );
                }
                $req = reset( $reqs );
 
index 2d7f5df..b5fa8ed 100644 (file)
@@ -52,7 +52,7 @@ class ApiResetPassword extends ApiBase {
 
        public function execute() {
                if ( !$this->hasAnyRoutes() ) {
-                       $this->dieUsage( 'No password reset routes are available.', 'moduledisabled' );
+                       $this->dieWithError( 'apihelp-resetpassword-description-noroutes', 'moduledisabled' );
                }
 
                $params = $this->extractRequestParams() + [
index 6e27fc8..61a4394 100644 (file)
@@ -413,11 +413,9 @@ class ApiResult implements ApiSerializable {
 
                        $newsize = $this->size + self::size( $value );
                        if ( $this->maxSize !== false && $newsize > $this->maxSize ) {
-                               /// @todo Add i18n message when replacing calls to ->setWarning()
-                               $msg = new ApiRawMessage( 'This result was truncated because it would otherwise ' .
-                                       'be larger than the limit of $1 bytes', 'truncatedresult' );
-                               $msg->numParams( $this->maxSize );
-                               $this->errorFormatter->addWarning( 'result', $msg );
+                               $this->errorFormatter->addWarning(
+                                       'result', [ 'apiwarn-truncatedresult', Message::numParam( $this->maxSize ) ]
+                               );
                                return false;
                        }
                        $this->size = $newsize;
index ed9fba2..763aef5 100644 (file)
@@ -36,24 +36,22 @@ class ApiRevisionDelete extends ApiBase {
 
                $params = $this->extractRequestParams();
                $user = $this->getUser();
-               if ( !$user->isAllowed( RevisionDeleter::getRestriction( $params['type'] ) ) ) {
-                       $this->dieUsageMsg( 'badaccess-group0' );
-               }
+               $this->checkUserRightsAny( RevisionDeleter::getRestriction( $params['type'] ) );
 
                if ( $user->isBlocked() ) {
                        $this->dieBlocked( $user->getBlock() );
                }
 
                if ( !$params['ids'] ) {
-                       $this->dieUsage( "At least one value is required for 'ids'", 'badparams' );
+                       $this->dieWithError( [ 'apierror-paramempty', 'ids' ], 'paramempty_ids' );
                }
 
                $hide = $params['hide'] ?: [];
                $show = $params['show'] ?: [];
                if ( array_intersect( $hide, $show ) ) {
-                       $this->dieUsage( "Mutually exclusive values for 'hide' and 'show'", 'badparams' );
+                       $this->dieWithError( 'apierror-revdel-mutuallyexclusive', 'badparams' );
                } elseif ( !$hide && !$show ) {
-                       $this->dieUsage( "At least one value is required for 'hide' or 'show'", 'badparams' );
+                       $this->dieWithError( 'apierror-revdel-paramneeded', 'badparams' );
                }
                $bits = [
                        'content' => RevisionDeleter::getRevdelConstant( $params['type'] ),
@@ -72,9 +70,7 @@ class ApiRevisionDelete extends ApiBase {
                }
 
                if ( $params['suppress'] === 'yes' ) {
-                       if ( !$user->isAllowed( 'suppressrevision' ) ) {
-                               $this->dieUsageMsg( 'badaccess-group0' );
-                       }
+                       $this->checkUserRightsAny( 'suppressrevision' );
                        $bitfield[Revision::DELETED_RESTRICTED] = 1;
                } elseif ( $params['suppress'] === 'no' ) {
                        $bitfield[Revision::DELETED_RESTRICTED] = 0;
@@ -88,7 +84,7 @@ class ApiRevisionDelete extends ApiBase {
                }
                $targetObj = RevisionDeleter::suggestTarget( $params['type'], $targetObj, $params['ids'] );
                if ( $targetObj === null ) {
-                       $this->dieUsage( 'A target title is required for this RevDel type', 'needtarget' );
+                       $this->dieWithError( [ 'apierror-revdel-needtarget' ], 'needtarget' );
                }
 
                $list = RevisionDeleter::createList(
@@ -124,49 +120,19 @@ class ApiRevisionDelete extends ApiBase {
                $ret = [
                        'status' => $status->isOK() ? 'Success' : 'Fail',
                ];
-               $errors = $this->formatStatusMessages( $status->getErrorsByType( 'error' ) );
+
+               $errors = $this->getErrorFormatter()->arrayFromStatus( $status, 'error' );
                if ( $errors ) {
-                       ApiResult::setIndexedTagName( $errors, 'e' );
                        $ret['errors'] = $errors;
                }
-               $warnings = $this->formatStatusMessages( $status->getErrorsByType( 'warning' ) );
+               $warnings = $this->getErrorFormatter()->arrayFromStatus( $status, 'warning' );
                if ( $warnings ) {
-                       ApiResult::setIndexedTagName( $warnings, 'w' );
                        $ret['warnings'] = $warnings;
                }
 
                return $ret;
        }
 
-       private function formatStatusMessages( $messages ) {
-               if ( !$messages ) {
-                       return [];
-               }
-               $ret = [];
-               foreach ( $messages as $m ) {
-                       if ( $m['message'] instanceof Message ) {
-                               $msg = $m['message'];
-                               $message = [ 'message' => $msg->getKey() ];
-                               if ( $msg->getParams() ) {
-                                       $message['params'] = $msg->getParams();
-                                       ApiResult::setIndexedTagName( $message['params'], 'p' );
-                               }
-                       } else {
-                               $message = [ 'message' => $m['message'] ];
-                               $msg = wfMessage( $m['message'] );
-                               if ( isset( $m['params'] ) ) {
-                                       $message['params'] = $m['params'];
-                                       ApiResult::setIndexedTagName( $message['params'], 'p' );
-                                       $msg->params( $m['params'] );
-                               }
-                       }
-                       $message['rendered'] = $msg->useDatabase( false )->inLanguage( 'en' )->plain();
-                       $ret[] = $message;
-               }
-
-               return $ret;
-       }
-
        public function mustBePosted() {
                return true;
        }
index b9911da..c802087 100644 (file)
@@ -69,24 +69,8 @@ class ApiRollback extends ApiBase {
                        $params['tags']
                );
 
-               // We don't care about multiple errors, just report one of them
                if ( $retval ) {
-                       if ( isset( $retval[0][0] ) &&
-                               ( $retval[0][0] == 'alreadyrolled' || $retval[0][0] == 'cantrollback' )
-                       ) {
-                               $error = $retval[0];
-                               $userMessage = $this->msg( $error[0], array_slice( $error, 1 ) );
-                               // dieUsageMsg() doesn't support $extraData
-                               $errorCode = $error[0];
-                               $errorInfo = isset( ApiBase::$messageMap[$errorCode] ) ?
-                                       ApiBase::$messageMap[$errorCode]['info'] :
-                                       $errorCode;
-                               $this->dieUsage( $errorInfo, $errorCode, 0, [
-                                       'messageHtml' => $userMessage->parseAsBlock()
-                               ] );
-                       }
-
-                       $this->dieUsageMsg( reset( $retval ) );
+                       $this->dieStatus( $this->errorArrayToStatus( $retval, $user ) );
                }
 
                $watch = 'preferences';
@@ -181,7 +165,7 @@ class ApiRollback extends ApiBase {
                        ? $params['user']
                        : User::getCanonicalName( $params['user'] );
                if ( !$this->mUser ) {
-                       $this->dieUsageMsg( [ 'invaliduser', $params['user'] ] );
+                       $this->dieWithError( [ 'apierror-invaliduser', wfEscapeWikiText( $params['user'] ) ] );
                }
 
                return $this->mUser;
@@ -202,17 +186,17 @@ class ApiRollback extends ApiBase {
                if ( isset( $params['title'] ) ) {
                        $this->mTitleObj = Title::newFromText( $params['title'] );
                        if ( !$this->mTitleObj || $this->mTitleObj->isExternal() ) {
-                               $this->dieUsageMsg( [ 'invalidtitle', $params['title'] ] );
+                               $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $params['title'] ) ] );
                        }
                } elseif ( isset( $params['pageid'] ) ) {
                        $this->mTitleObj = Title::newFromID( $params['pageid'] );
                        if ( !$this->mTitleObj ) {
-                               $this->dieUsageMsg( [ 'nosuchpageid', $params['pageid'] ] );
+                               $this->dieWithError( [ 'apierror-nosuchpageid', $params['pageid'] ] );
                        }
                }
 
                if ( !$this->mTitleObj->exists() ) {
-                       $this->dieUsageMsg( 'notanarticle' );
+                       $this->dieWithError( 'apierror-missingtitle' );
                }
 
                return $this->mTitleObj;
index 3412f38..5769ff6 100644 (file)
@@ -38,11 +38,9 @@ class ApiSetNotificationTimestamp extends ApiBase {
                $user = $this->getUser();
 
                if ( $user->isAnon() ) {
-                       $this->dieUsage( 'Anonymous users cannot use watchlist change notifications', 'notloggedin' );
-               }
-               if ( !$user->isAllowed( 'editmywatchlist' ) ) {
-                       $this->dieUsage( 'You don\'t have permission to edit your watchlist', 'permissiondenied' );
+                       $this->dieWithError( 'watchlistanontext', 'notloggedin' );
                }
+               $this->checkUserRightsAny( 'editmywatchlist' );
 
                $params = $this->extractRequestParams();
                $this->requireMaxOneParameter( $params, 'timestamp', 'torevid', 'newerthanrevid' );
@@ -52,8 +50,12 @@ class ApiSetNotificationTimestamp extends ApiBase {
 
                $pageSet = $this->getPageSet();
                if ( $params['entirewatchlist'] && $pageSet->getDataSource() !== null ) {
-                       $this->dieUsage(
-                               "Cannot use 'entirewatchlist' at the same time as '{$pageSet->getDataSource()}'",
+                       $this->dieWithError(
+                               [
+                                       'apierror-invalidparammix-cannotusewith',
+                                       $this->encodeParamName( 'entirewatchlist' ),
+                                       $pageSet->encodeParamName( $pageSet->getDataSource() )
+                               ],
                                'multisource'
                        );
                }
@@ -71,7 +73,7 @@ class ApiSetNotificationTimestamp extends ApiBase {
 
                if ( isset( $params['torevid'] ) ) {
                        if ( $params['entirewatchlist'] || $pageSet->getGoodTitleCount() > 1 ) {
-                               $this->dieUsage( 'torevid may only be used with a single page', 'multpages' );
+                               $this->dieWithError( [ 'apierror-multpages', $this->encodeParamName( 'torevid' ) ] );
                        }
                        $title = reset( $pageSet->getGoodTitles() );
                        if ( $title ) {
@@ -85,7 +87,7 @@ class ApiSetNotificationTimestamp extends ApiBase {
                        }
                } elseif ( isset( $params['newerthanrevid'] ) ) {
                        if ( $params['entirewatchlist'] || $pageSet->getGoodTitleCount() > 1 ) {
-                               $this->dieUsage( 'newerthanrevid may only be used with a single page', 'multpages' );
+                               $this->dieWithError( [ 'apierror-multpages', $this->encodeParamName( 'newerthanrevid' ) ] );
                        }
                        $title = reset( $pageSet->getGoodTitles() );
                        if ( $title ) {
index 92cbe90..e29fda5 100644 (file)
@@ -51,7 +51,7 @@ class ApiStashEdit extends ApiBase {
                $params = $this->extractRequestParams();
 
                if ( $user->isBot() ) { // sanity
-                       $this->dieUsage( 'This interface is not supported for bots', 'botsnotsupported' );
+                       $this->dieWithError( 'apierror-botsnotsupported' );
                }
 
                $cache = ObjectCache::getLocalClusterInstance();
@@ -61,9 +61,14 @@ class ApiStashEdit extends ApiBase {
                if ( !ContentHandler::getForModelID( $params['contentmodel'] )
                        ->isSupportedFormat( $params['contentformat'] )
                ) {
-                       $this->dieUsage( 'Unsupported content model/format', 'badmodelformat' );
+                       $this->dieWithError(
+                               [ 'apierror-badformat-generic', $params['contentformat'], $params['contentmodel'] ],
+                               'badmodelformat'
+                       );
                }
 
+               $this->requireAtLeastOneParameter( $params, 'stashedtexthash', 'text' );
+
                $text = null;
                $textHash = null;
                if ( strlen( $params['stashedtexthash'] ) ) {
@@ -72,15 +77,18 @@ class ApiStashEdit extends ApiBase {
                        $textKey = $cache->makeKey( 'stashedit', 'text', $textHash );
                        $text = $cache->get( $textKey );
                        if ( !is_string( $text ) ) {
-                               $this->dieUsage( 'No stashed text found with the given hash', 'missingtext' );
+                               $this->dieWithError( 'apierror-stashedit-missingtext', 'missingtext' );
                        }
                } elseif ( $params['text'] !== null ) {
                        // Trim and fix newlines so the key SHA1's match (see WebRequest::getText())
                        $text = rtrim( str_replace( "\r\n", "\n", $params['text'] ) );
                        $textHash = sha1( $text );
                } else {
-                       $this->dieUsage(
-                               'The text or stashedtexthash parameter must be given', 'missingtextparam' );
+                       $this->dieWithError( [
+                               'apierror-missingparam-at-least-one-of',
+                               Message::listParam( [ '<var>stashedtexthash</var>', '<var>text</var>' ] ),
+                               2,
+                       ], 'missingparam' );
                }
 
                $textContent = ContentHandler::makeContent(
@@ -91,11 +99,11 @@ class ApiStashEdit extends ApiBase {
                        // Page exists: get the merged content with the proposed change
                        $baseRev = Revision::newFromPageId( $page->getId(), $params['baserevid'] );
                        if ( !$baseRev ) {
-                               $this->dieUsage( "No revision ID {$params['baserevid']}", 'missingrev' );
+                               $this->dieWithError( [ 'apierror-nosuchrevid', $params['baserevid'] ] );
                        }
                        $currentRev = $page->getRevision();
                        if ( !$currentRev ) {
-                               $this->dieUsage( "No current revision of page ID {$page->getId()}", 'missingrev' );
+                               $this->dieWithError( [ 'apierror-missingrev-pageid', $page->getId() ], 'missingrev' );
                        }
                        // Merge in the new version of the section to get the proposed version
                        $editContent = $page->replaceSectionAtRev(
@@ -105,7 +113,7 @@ class ApiStashEdit extends ApiBase {
                                $baseRev->getId()
                        );
                        if ( !$editContent ) {
-                               $this->dieUsage( 'Could not merge updated section.', 'replacefailed' );
+                               $this->dieWithError( 'apierror-sectionreplacefailed', 'replacefailed' );
                        }
                        if ( $currentRev->getId() == $baseRev->getId() ) {
                                // Base revision was still the latest; nothing to merge
@@ -115,7 +123,7 @@ class ApiStashEdit extends ApiBase {
                                $baseContent = $baseRev->getContent();
                                $currentContent = $currentRev->getContent();
                                if ( !$baseContent || !$currentContent ) {
-                                       $this->dieUsage( "Missing content for page ID {$page->getId()}", 'missingrev' );
+                                       $this->dieWithError( [ 'apierror-missingcontent-pageid', $page->getId() ], 'missingrev' );
                                }
                                $handler = ContentHandler::getForModelID( $baseContent->getModel() );
                                $content = $handler->merge3( $baseContent, $editContent, $currentContent );
index f88c2db..f6c0584 100644 (file)
@@ -30,10 +30,7 @@ class ApiTag extends ApiBase {
                $user = $this->getUser();
 
                // make sure the user is allowed
-               if ( !$user->isAllowed( 'changetags' ) ) {
-                       $this->dieUsage( "You don't have permission to add or remove change tags from individual edits",
-                               'permissiondenied' );
-               }
+               $this->checkUserRightsAny( 'changetags' );
 
                if ( $user->isBlocked() ) {
                        $this->dieBlocked( $user->getBlock() );
@@ -88,7 +85,8 @@ class ApiTag extends ApiBase {
 
                if ( !$valid ) {
                        $idResult['status'] = 'error';
-                       $idResult += $this->parseMsg( [ "nosuch$type", $id ] );
+                       // Messages: apierror-nosuchrcid apierror-nosuchrevid apierror-nosuchlogid
+                       $idResult += $this->getErrorFormatter()->formatMessage( [ "apierror-nosuch$type", $id ] );
                        return $idResult;
                }
 
index 4940394..fc2951a 100644 (file)
 class ApiTokens extends ApiBase {
 
        public function execute() {
-               $this->setWarning(
-                       'action=tokens has been deprecated. Please use action=query&meta=tokens instead.'
+               $this->addDeprecation(
+                       [ 'apiwarn-deprecation-withreplacement', 'action=tokens', 'action=query&meta=tokens' ],
+                       'action=tokens'
                );
-               $this->logFeatureUsage( 'action=tokens' );
 
                $params = $this->extractRequestParams();
                $res = [
@@ -46,7 +46,7 @@ class ApiTokens extends ApiBase {
                        $val = call_user_func( $types[$type], null, null );
 
                        if ( $val === false ) {
-                               $this->setWarning( "Action '$type' is not allowed for the current user" );
+                               $this->addWarning( [ 'apiwarn-tokennotallowed', $type ] );
                        } else {
                                $res[$type . 'token'] = $val;
                        }
index ace41a4..523a888 100644 (file)
@@ -39,25 +39,18 @@ class ApiUnblock extends ApiBase {
                $user = $this->getUser();
                $params = $this->extractRequestParams();
 
-               if ( is_null( $params['id'] ) && is_null( $params['user'] ) ) {
-                       $this->dieUsageMsg( 'unblock-notarget' );
-               }
-               if ( !is_null( $params['id'] ) && !is_null( $params['user'] ) ) {
-                       $this->dieUsageMsg( 'unblock-idanduser' );
-               }
+               $this->requireOnlyOneParameter( $params, 'id', 'user' );
 
                if ( !$user->isAllowed( 'block' ) ) {
-                       $this->dieUsageMsg( 'cantunblock' );
+                       $this->dieWithError( 'apierror-permissiondenied-unblock', 'permissiondenied' );
                }
                # bug 15810: blocked admins should have limited access here
                if ( $user->isBlocked() ) {
                        $status = SpecialBlock::checkUnblockSelf( $params['user'], $user );
                        if ( $status !== true ) {
-                               $msg = $this->parseMsg( $status );
-                               $this->dieUsage(
-                                       $msg['info'],
-                                       $msg['code'],
-                                       0,
+                               $this->dieWithError(
+                                       $status,
+                                       null,
                                        [ 'blockinfo' => ApiQueryUserInfo::getBlockInfo( $user->getBlock() ) ]
                                );
                        }
@@ -79,7 +72,7 @@ class ApiUnblock extends ApiBase {
                $block = Block::newFromTarget( $data['Target'] );
                $retval = SpecialUnblock::processUnblock( $data, $this->getContext() );
                if ( $retval !== true ) {
-                       $this->dieUsageMsg( $retval[0] );
+                       $this->dieStatus( $this->errorArrayToStatus( $retval ) );
                }
 
                $res['id'] = $block->getId();
index e24f2ce..7fda1ea 100644 (file)
@@ -33,18 +33,16 @@ class ApiUndelete extends ApiBase {
                $this->useTransactionalTimeLimit();
 
                $params = $this->extractRequestParams();
-               $user = $this->getUser();
-               if ( !$user->isAllowed( 'undelete' ) ) {
-                       $this->dieUsageMsg( 'permdenied-undelete' );
-               }
+               $this->checkUserRightsAny( 'undelete' );
 
+               $user = $this->getUser();
                if ( $user->isBlocked() ) {
                        $this->dieBlocked( $user->getBlock() );
                }
 
                $titleObj = Title::newFromText( $params['title'] );
                if ( !$titleObj || $titleObj->isExternal() ) {
-                       $this->dieUsageMsg( [ 'invalidtitle', $params['title'] ] );
+                       $this->dieWithError( [ 'apierror-invalidtitle', wfEscapeWikiText( $params['title'] ) ] );
                }
 
                // Check if user can add tags
@@ -76,7 +74,7 @@ class ApiUndelete extends ApiBase {
                        $params['tags']
                );
                if ( !is_array( $retval ) ) {
-                       $this->dieUsageMsg( 'cannotundelete' );
+                       $this->dieWithError( 'apierror-cantundelete' );
                }
 
                if ( $retval[1] ) {
index 7b44f40..6bdd68f 100644 (file)
@@ -36,7 +36,7 @@ class ApiUpload extends ApiBase {
        public function execute() {
                // Check whether upload is enabled
                if ( !UploadBase::isEnabled() ) {
-                       $this->dieUsageMsg( 'uploaddisabled' );
+                       $this->dieWithError( 'uploaddisabled' );
                }
 
                $user = $this->getUser();
@@ -61,11 +61,10 @@ class ApiUpload extends ApiBase {
                        if ( !$this->selectUploadModule() ) {
                                return; // not a true upload, but a status request or similar
                        } elseif ( !isset( $this->mUpload ) ) {
-                               $this->dieUsage( 'No upload module set', 'nomodule' );
+                               $this->dieDebug( __METHOD__, 'No upload module set' );
                        }
                } catch ( UploadStashException $e ) { // XXX: don't spam exception log
-                       list( $msg, $code ) = $this->handleStashException( get_class( $e ), $e->getMessage() );
-                       $this->dieUsage( $msg, $code );
+                       $this->dieStatus( $this->handleStashException( $e ) );
                }
 
                // First check permission to upload
@@ -75,19 +74,17 @@ class ApiUpload extends ApiBase {
                /** @var $status Status */
                $status = $this->mUpload->fetchFile();
                if ( !$status->isGood() ) {
-                       $errors = $status->getErrorsArray();
-                       $error = array_shift( $errors[0] );
-                       $this->dieUsage( 'Error fetching file from remote source', $error, 0, $errors[0] );
+                       $this->dieStatus( $status );
                }
 
                // Check if the uploaded file is sane
                if ( $this->mParams['chunk'] ) {
                        $maxSize = UploadBase::getMaxUploadSize();
                        if ( $this->mParams['filesize'] > $maxSize ) {
-                               $this->dieUsage( 'The file you submitted was too large', 'file-too-large' );
+                               $this->dieWithError( 'file-too-large' );
                        }
                        if ( !$this->mUpload->getTitle() ) {
-                               $this->dieUsage( 'Invalid file title supplied', 'internal-error' );
+                               $this->dieWithError( 'illegal-filename' );
                        }
                } elseif ( $this->mParams['async'] && $this->mParams['filekey'] ) {
                        // defer verification to background process
@@ -102,7 +99,7 @@ class ApiUpload extends ApiBase {
                if ( !$this->mParams['stash'] ) {
                        $permErrors = $this->mUpload->verifyTitlePermissions( $user );
                        if ( $permErrors !== true ) {
-                               $this->dieRecoverableError( $permErrors[0], 'filename' );
+                               $this->dieRecoverableError( $permErrors, 'filename' );
                        }
                }
 
@@ -110,8 +107,7 @@ class ApiUpload extends ApiBase {
                try {
                        $result = $this->getContextResult();
                } catch ( UploadStashException $e ) { // XXX: don't spam exception log
-                       list( $msg, $code ) = $this->handleStashException( get_class( $e ), $e->getMessage() );
-                       $this->dieUsage( $msg, $code );
+                       $this->dieStatus( $this->handleStashException( $e ) );
                }
                $this->getResult()->addValue( null, $this->getModuleName(), $result );
 
@@ -146,7 +142,7 @@ class ApiUpload extends ApiBase {
                // Check throttle after we've handled warnings
                if ( UploadBase::isThrottled( $this->getUser() )
                ) {
-                       $this->dieUsageMsg( 'actionthrottledtext' );
+                       $this->dieWithError( 'apierror-ratelimited' );
                }
 
                // This is the most common case -- a normal upload with no warnings
@@ -208,16 +204,12 @@ class ApiUpload extends ApiBase {
 
                // Sanity check sizing
                if ( $totalSoFar > $this->mParams['filesize'] ) {
-                       $this->dieUsage(
-                               'Offset plus current chunk is greater than claimed file size', 'invalid-chunk'
-                       );
+                       $this->dieWithError( 'apierror-invalid-chunk' );
                }
 
                // Enforce minimum chunk size
                if ( $totalSoFar != $this->mParams['filesize'] && $chunkSize < $minChunkSize ) {
-                       $this->dieUsage(
-                               "Minimum chunk size is $minChunkSize bytes for non-final chunks", 'chunk-too-small'
-                       );
+                       $this->dieWithError( [ 'apierror-chunk-too-small', Message::numParam( $minChunkSize ) ] );
                }
 
                if ( $this->mParams['offset'] == 0 ) {
@@ -229,11 +221,9 @@ class ApiUpload extends ApiBase {
                        $progress = UploadBase::getSessionStatus( $this->getUser(), $filekey );
                        if ( !$progress ) {
                                // Probably can't get here, but check anyway just in case
-                               $this->dieUsage( 'No chunked upload session with this key', 'stashfailed' );
+                               $this->dieWithError( 'apierror-stashfailed-nosession', 'stashfailed' );
                        } elseif ( $progress['result'] !== 'Continue' || $progress['stage'] !== 'uploading' ) {
-                               $this->dieUsage(
-                                       'Chunked upload is already completed, check status for details', 'stashfailed'
-                               );
+                               $this->dieWithError( 'apierror-stashfailed-complete', 'stashfailed' );
                        }
 
                        $status = $this->mUpload->addChunk(
@@ -352,16 +342,13 @@ class ApiUpload extends ApiBase {
                        list( $exceptionType, $message ) = $status->getMessage()->getParams();
                        $debugMessage = 'Stashing temporary file failed: ' . $exceptionType . ' ' . $message;
                        wfDebug( __METHOD__ . ' ' . $debugMessage . "\n" );
-                       list( $msg, $code ) = $this->handleStashException( $exceptionType, $message );
-                       $status = Status::newFatal( new ApiRawMessage( $msg, $code ) );
                }
 
                // Bad status
                if ( $failureMode !== 'optional' ) {
                        $this->dieStatus( $status );
                } else {
-                       list( $code, $msg ) = $this->getErrorFromStatus( $status );
-                       $data['stashfailed'] = $msg;
+                       $data['stasherrors'] = $this->getErrorFormatter()->arrayFromStatus( $status );
                        return null;
                }
        }
@@ -370,25 +357,25 @@ class ApiUpload extends ApiBase {
         * Throw an error that the user can recover from by providing a better
         * value for $parameter
         *
-        * @param array|string|MessageSpecifier $error Error suitable for passing to dieUsageMsg()
-        * @param string $parameter Parameter that needs revising
-        * @param array $data Optional extra data to pass to the user
-        * @param string $code Error code to use if the error is unknown
-        * @throws UsageException
+        * @param array $errors Array of Message objects, message keys, key+param
+        *  arrays, or StatusValue::getErrors()-style arrays
+        * @param string|null $parameter Parameter that needs revising
+        * @throws ApiUsageException
         */
-       private function dieRecoverableError( $error, $parameter, $data = [], $code = 'unknownerror' ) {
+       private function dieRecoverableError( $errors, $parameter = null ) {
                $this->performStash( 'optional', $data );
-               $data['invalidparameter'] = $parameter;
 
-               $parsed = $this->parseMsg( $error );
-               if ( isset( $parsed['data'] ) ) {
-                       $data = array_merge( $data, $parsed['data'] );
-               }
-               if ( $parsed['code'] === 'unknownerror' ) {
-                       $parsed['code'] = $code;
+               if ( $parameter ) {
+                       $data['invalidparameter'] = $parameter;
                }
 
-               $this->dieUsage( $parsed['info'], $parsed['code'], 0, $data );
+               $sv = StatusValue::newGood();
+               foreach ( $errors as $error ) {
+                       $msg = ApiMessage::create( $error );
+                       $msg->setApiData( $msg->getApiData() + $data );
+                       $sv->fatal( $msg );
+               }
+               $this->dieStatus( $sv );
        }
 
        /**
@@ -398,20 +385,18 @@ class ApiUpload extends ApiBase {
         * @param Status $status
         * @param string $overrideCode Error code to use if there isn't one from IApiMessage
         * @param array|null $moreExtraData
-        * @throws UsageException
+        * @throws ApiUsageException
         */
        public function dieStatusWithCode( $status, $overrideCode, $moreExtraData = null ) {
-               $extraData = null;
-               list( $code, $msg ) = $this->getErrorFromStatus( $status, $extraData );
-               $errors = $status->getErrorsByType( 'error' ) ?: $status->getErrorsByType( 'warning' );
-               if ( !( $errors[0]['message'] instanceof IApiMessage ) ) {
-                       $code = $overrideCode;
-               }
-               if ( $moreExtraData ) {
-                       $extraData = $extraData ?: [];
-                       $extraData += $moreExtraData;
+               $sv = StatusValue::newGood();
+               foreach ( $status->getErrors() as $error ) {
+                       $msg = ApiMessage::create( $error, $overrideCode );
+                       if ( $moreExtraData ) {
+                               $msg->setApiData( $msg->getApiData() + $moreExtraData );
+                       }
+                       $sv->fatal( $msg );
                }
-               $this->dieUsage( $msg, $code, 0, $extraData );
+               $this->dieStatus( $sv );
        }
 
        /**
@@ -434,7 +419,7 @@ class ApiUpload extends ApiBase {
                if ( $this->mParams['filekey'] && $this->mParams['checkstatus'] ) {
                        $progress = UploadBase::getSessionStatus( $this->getUser(), $this->mParams['filekey'] );
                        if ( !$progress ) {
-                               $this->dieUsage( 'No result in status data', 'missingresult' );
+                               $this->dieWithError( 'api-upload-missingresult', 'missingresult' );
                        } elseif ( !$progress['status']->isGood() ) {
                                $this->dieStatusWithCode( $progress['status'], 'stashfailed' );
                        }
@@ -466,7 +451,7 @@ class ApiUpload extends ApiBase {
 
                // The following modules all require the filename parameter to be set
                if ( is_null( $this->mParams['filename'] ) ) {
-                       $this->dieUsageMsg( [ 'missingparam', 'filename' ] );
+                       $this->dieWithError( [ 'apierror-missingparam', 'filename' ] );
                }
 
                if ( $this->mParams['chunk'] ) {
@@ -474,7 +459,7 @@ class ApiUpload extends ApiBase {
                        $this->mUpload = new UploadFromChunks( $this->getUser() );
                        if ( isset( $this->mParams['filekey'] ) ) {
                                if ( $this->mParams['offset'] === 0 ) {
-                                       $this->dieUsage( 'Cannot supply a filekey when offset is 0', 'badparams' );
+                                       $this->dieWithError( 'apierror-upload-filekeynotallowed', 'filekeynotallowed' );
                                }
 
                                // handle new chunk
@@ -485,7 +470,7 @@ class ApiUpload extends ApiBase {
                                );
                        } else {
                                if ( $this->mParams['offset'] !== 0 ) {
-                                       $this->dieUsage( 'Must supply a filekey when offset is non-zero', 'badparams' );
+                                       $this->dieWithError( 'apierror-upload-filekeyneeded', 'filekeyneeded' );
                                }
 
                                // handle first chunk
@@ -497,7 +482,7 @@ class ApiUpload extends ApiBase {
                } elseif ( isset( $this->mParams['filekey'] ) ) {
                        // Upload stashed in a previous request
                        if ( !UploadFromStash::isValidKey( $this->mParams['filekey'] ) ) {
-                               $this->dieUsageMsg( 'invalid-file-key' );
+                               $this->dieWithError( 'apierror-invalid-file-key' );
                        }
 
                        $this->mUpload = new UploadFromStash( $this->getUser() );
@@ -515,15 +500,15 @@ class ApiUpload extends ApiBase {
                } elseif ( isset( $this->mParams['url'] ) ) {
                        // Make sure upload by URL is enabled:
                        if ( !UploadFromUrl::isEnabled() ) {
-                               $this->dieUsageMsg( 'copyuploaddisabled' );
+                               $this->dieWithError( 'copyuploaddisabled' );
                        }
 
                        if ( !UploadFromUrl::isAllowedHost( $this->mParams['url'] ) ) {
-                               $this->dieUsageMsg( 'copyuploadbaddomain' );
+                               $this->dieWithError( 'apierror-copyuploadbaddomain' );
                        }
 
                        if ( !UploadFromUrl::isAllowedUrl( $this->mParams['url'] ) ) {
-                               $this->dieUsageMsg( 'copyuploadbadurl' );
+                               $this->dieWithError( 'apierror-copyuploadbadurl' );
                        }
 
                        $this->mUpload = new UploadFromUrl;
@@ -545,10 +530,10 @@ class ApiUpload extends ApiBase {
 
                if ( $permission !== true ) {
                        if ( !$user->isLoggedIn() ) {
-                               $this->dieUsageMsg( [ 'mustbeloggedin', 'upload' ] );
+                               $this->dieWithError( [ 'apierror-mustbeloggedin', $this->msg( 'action-upload' ) ] );
                        }
 
-                       $this->dieUsageMsg( 'badaccess-groups' );
+                       $this->dieStatus( User::newFatalPermissionDeniedStatus( $permission ) );
                }
 
                // Check blocks
@@ -583,28 +568,31 @@ class ApiUpload extends ApiBase {
                switch ( $verification['status'] ) {
                        // Recoverable errors
                        case UploadBase::MIN_LENGTH_PARTNAME:
-                               $this->dieRecoverableError( 'filename-tooshort', 'filename' );
+                               $this->dieRecoverableError( [ 'filename-tooshort' ], 'filename' );
                                break;
                        case UploadBase::ILLEGAL_FILENAME:
-                               $this->dieRecoverableError( 'illegal-filename', 'filename',
-                                       [ 'filename' => $verification['filtered'] ] );
+                               $this->dieRecoverableError(
+                                       [ ApiMessage::create(
+                                               'illegal-filename', null, [ 'filename' => $verification['filtered'] ]
+                                       ) ], 'filename'
+                               );
                                break;
                        case UploadBase::FILENAME_TOO_LONG:
-                               $this->dieRecoverableError( 'filename-toolong', 'filename' );
+                               $this->dieRecoverableError( [ 'filename-toolong' ], 'filename' );
                                break;
                        case UploadBase::FILETYPE_MISSING:
-                               $this->dieRecoverableError( 'filetype-missing', 'filename' );
+                               $this->dieRecoverableError( [ 'filetype-missing' ], 'filename' );
                                break;
                        case UploadBase::WINDOWS_NONASCII_FILENAME:
-                               $this->dieRecoverableError( 'windows-nonascii-filename', 'filename' );
+                               $this->dieRecoverableError( [ 'windows-nonascii-filename' ], 'filename' );
                                break;
 
                        // Unrecoverable errors
                        case UploadBase::EMPTY_FILE:
-                               $this->dieUsage( 'The file you submitted was empty', 'empty-file' );
+                               $this->dieWithError( 'empty-file' );
                                break;
                        case UploadBase::FILE_TOO_LARGE:
-                               $this->dieUsage( 'The file you submitted was too large', 'file-too-large' );
+                               $this->dieWithError( 'file-too-large' );
                                break;
 
                        case UploadBase::FILETYPE_BADTYPE:
@@ -612,57 +600,47 @@ class ApiUpload extends ApiBase {
                                        'filetype' => $verification['finalExt'],
                                        'allowed' => array_values( array_unique( $this->getConfig()->get( 'FileExtensions' ) ) )
                                ];
+                               $extensions = array_unique( $this->getConfig()->get( 'FileExtensions' ) );
+                               $msg = [
+                                       'filetype-banned-type',
+                                       null, // filled in below
+                                       Message::listParam( $extensions, 'comma' ),
+                                       count( $extensions ),
+                                       null, // filled in below
+                               ];
                                ApiResult::setIndexedTagName( $extradata['allowed'], 'ext' );
 
-                               $msg = 'Filetype not permitted: ';
                                if ( isset( $verification['blacklistedExt'] ) ) {
-                                       $msg .= implode( ', ', $verification['blacklistedExt'] );
+                                       $msg[1] = Message::listParam( $verification['blacklistedExt'], 'comma' );
+                                       $msg[4] = count( $verification['blacklistedExt'] );
                                        $extradata['blacklisted'] = array_values( $verification['blacklistedExt'] );
                                        ApiResult::setIndexedTagName( $extradata['blacklisted'], 'ext' );
                                } else {
-                                       $msg .= $verification['finalExt'];
+                                       $msg[1] = $verification['finalExt'];
+                                       $msg[4] = 1;
                                }
-                               $this->dieUsage( $msg, 'filetype-banned', 0, $extradata );
+
+                               $this->dieWithError( $msg, 'filetype-banned', $extradata );
                                break;
+
                        case UploadBase::VERIFICATION_ERROR:
-                               $parsed = $this->parseMsg( $verification['details'] );
-                               $info = "This file did not pass file verification: {$parsed['info']}";
-                               if ( $verification['details'][0] instanceof IApiMessage ) {
-                                       $code = $parsed['code'];
-                               } else {
-                                       // For backwards-compatibility, all of the errors from UploadBase::verifyFile() are
-                                       // reported as 'verification-error', and the real error code is reported in 'details'.
-                                       $code = 'verification-error';
-                               }
-                               if ( $verification['details'][0] instanceof IApiMessage ) {
-                                       $msg = $verification['details'][0];
+                               $msg = ApiMessage::create( $verification['details'], 'verification-error' );
+                               if ( $verification['details'][0] instanceof MessageSpecifier ) {
                                        $details = array_merge( [ $msg->getKey() ], $msg->getParams() );
                                } else {
                                        $details = $verification['details'];
                                }
                                ApiResult::setIndexedTagName( $details, 'detail' );
-                               $data = [ 'details' => $details ];
-                               if ( isset( $parsed['data'] ) ) {
-                                       $data = array_merge( $data, $parsed['data'] );
-                               }
-
-                               $this->dieUsage( $info, $code, 0, $data );
+                               $msg->setApiData( $msg->getApiData() + [ 'details' => $details ] );
+                               $this->dieWithError( $msg );
                                break;
+
                        case UploadBase::HOOK_ABORTED:
-                               if ( is_array( $verification['error'] ) ) {
-                                       $params = $verification['error'];
-                               } elseif ( $verification['error'] !== '' ) {
-                                       $params = [ $verification['error'] ];
-                               } else {
-                                       $params = [ 'hookaborted' ];
-                               }
-                               $key = array_shift( $params );
-                               $msg = $this->msg( $key, $params )->inLanguage( 'en' )->useDatabase( false )->text();
-                               $this->dieUsage( $msg, 'hookaborted', 0, [ 'details' => $verification['error'] ] );
+                               $this->dieWithError( $params, 'hookaborted', [ 'details' => $verification['error'] ] );
                                break;
                        default:
-                               $this->dieUsage( 'An unknown error occurred', 'unknown-error',
-                                       0, [ 'details' => [ 'code' => $verification['status'] ] ] );
+                               $this->dieWithError( 'apierror-unknownerror-nocode', 'unknown-error',
+                                       [ 'details' => [ 'code' => $verification['status'] ] ] );
                                break;
                }
        }
@@ -735,41 +713,31 @@ class ApiUpload extends ApiBase {
 
        /**
         * Handles a stash exception, giving a useful error to the user.
-        * @param string $exceptionType Class name of the exception we encountered.
-        * @param string $message Message of the exception we encountered.
-        * @return array Array of message and code, suitable for passing to dieUsage()
+        * @todo Internationalize the exceptions
+        * @param Exception $e
+        * @return StatusValue
         */
-       protected function handleStashException( $exceptionType, $message ) {
-               switch ( $exceptionType ) {
+       protected function handleStashException( $e ) {
+               $err = wfEscapeWikiText( $e->getMessage() );
+               switch ( get_class( $exception ) ) {
                        case 'UploadStashFileNotFoundException':
-                               return [
-                                       'Could not find the file in the stash: ' . $message,
-                                       'stashedfilenotfound'
-                               ];
+                               return StatusValue::newFatal( 'apierror-stashedfilenotfound', $err );
                        case 'UploadStashBadPathException':
-                               return [
-                                       'File key of improper format or otherwise invalid: ' . $message,
-                                       'stashpathinvalid'
-                               ];
+                               return StatusValue::newFatal( 'apierror-stashpathinvalid', $err );
                        case 'UploadStashFileException':
-                               return [
-                                       'Could not store upload in the stash: ' . $message,
-                                       'stashfilestorage'
-                               ];
+                               return StatusValue::newFatal( 'apierror-stashfilestorage', $err );
                        case 'UploadStashZeroLengthFileException':
-                               return [
-                                       'File is of zero length, and could not be stored in the stash: ' .
-                                               $message,
-                                       'stashzerolength'
-                               ];
+                               return StatusValue::newFatal( 'apierror-stashzerolength', $err );
                        case 'UploadStashNotLoggedInException':
-                               return [ 'Not logged in: ' . $message, 'stashnotloggedin' ];
+                               return StatusValue::newFatal( ApiMessage::create(
+                                       [ 'apierror-mustbeloggedin', $this->msg( 'action-upload' ) ], 'stashnotloggedin'
+                               ) );
                        case 'UploadStashWrongOwnerException':
-                               return [ 'Wrong owner: ' . $message, 'stashwrongowner' ];
+                               return StatusValue::newFatal( 'apierror-stashwrongowner', $err );
                        case 'UploadStashNoSuchKeyException':
-                               return [ 'No such filekey: ' . $message, 'stashnosuchfilekey' ];
+                               return StatusValue::newFatal( 'apierror-stashnosuchfilekey', $err );
                        default:
-                               return [ $exceptionType . ': ' . $message, 'stasherror' ];
+                               return StatusValue::newFatal( 'uploadstash-exception', get_class( $e ), $err );
                }
        }
 
@@ -821,7 +789,7 @@ class ApiUpload extends ApiBase {
                if ( $this->mParams['async'] ) {
                        $progress = UploadBase::getSessionStatus( $this->getUser(), $this->mParams['filekey'] );
                        if ( $progress && $progress['result'] === 'Poll' ) {
-                               $this->dieUsage( 'Upload from stash already in progress.', 'publishfailed' );
+                               $this->dieWithError( 'apierror-upload-inprogress', 'publishfailed' );
                        }
                        UploadBase::setSessionStatus(
                                $this->getUser(),
@@ -848,14 +816,7 @@ class ApiUpload extends ApiBase {
                                $this->mParams['text'], $watch, $this->getUser(), $this->mParams['tags'] );
 
                        if ( !$status->isGood() ) {
-                               // Is there really no better way to do this?
-                               $errors = $status->getErrorsByType( 'error' );
-                               $msg = array_merge( [ $errors[0]['message'] ], $errors[0]['params'] );
-                               $data = $status->getErrorsArray();
-                               ApiResult::setIndexedTagName( $data, 'error' );
-                               // For backwards-compatibility, we use the 'internal-error' fallback key and merge $data
-                               // into the root of the response (rather than something sane like [ 'details' => $data ]).
-                               $this->dieRecoverableError( $msg, null, $data, 'internal-error' );
+                               $this->dieRecoverableError( $status->getErrors() );
                        }
                        $result['result'] = 'Success';
                }
diff --git a/includes/api/ApiUsageException.php b/includes/api/ApiUsageException.php
new file mode 100644 (file)
index 0000000..7e21ab5
--- /dev/null
@@ -0,0 +1,217 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @defgroup API API
+ */
+
+/**
+ * This exception will be thrown when dieUsage is called to stop module execution.
+ *
+ * @ingroup API
+ * @deprecated since 1.29, use ApiUsageException instead
+ */
+class UsageException extends MWException {
+
+       private $mCodestr;
+
+       /**
+        * @var null|array
+        */
+       private $mExtraData;
+
+       /**
+        * @param string $message
+        * @param string $codestr
+        * @param int $code
+        * @param array|null $extradata
+        */
+       public function __construct( $message, $codestr, $code = 0, $extradata = null ) {
+               parent::__construct( $message, $code );
+               $this->mCodestr = $codestr;
+               $this->mExtraData = $extradata;
+
+               // This should never happen, so throw an exception about it that will
+               // hopefully get logged with a backtrace (T138585)
+               if ( !is_string( $codestr ) || $codestr === '' ) {
+                       throw new InvalidArgumentException( 'Invalid $codestr, was ' .
+                               ( $codestr === '' ? 'empty string' : gettype( $codestr ) )
+                       );
+               }
+       }
+
+       /**
+        * @return string
+        */
+       public function getCodeString() {
+               return $this->mCodestr;
+       }
+
+       /**
+        * @return array
+        */
+       public function getMessageArray() {
+               $result = [
+                       'code' => $this->mCodestr,
+                       'info' => $this->getMessage()
+               ];
+               if ( is_array( $this->mExtraData ) ) {
+                       $result = array_merge( $result, $this->mExtraData );
+               }
+
+               return $result;
+       }
+
+       /**
+        * @return string
+        */
+       public function __toString() {
+               return "{$this->getCodeString()}: {$this->getMessage()}";
+       }
+}
+
+/**
+ * Exception used to abort API execution with an error
+ *
+ * If possible, use ApiBase::dieWithError() instead of throwing this directly.
+ *
+ * @ingroup API
+ * @note This currently extends UsageException for backwards compatibility, so
+ *  all the existing code that catches UsageException won't break when stuff
+ *  starts throwing ApiUsageException. Eventually UsageException will go away
+ *  and this will (probably) extend MWException directly.
+ */
+class ApiUsageException extends UsageException {
+
+       protected $modulePath;
+       protected $status;
+
+       /**
+        * @param ApiBase|null $module API module responsible for the error, if known
+        * @param StatusValue $status Status holding errors
+        * @param int $httpCode HTTP error code to use
+        */
+       public function __construct(
+               ApiBase $module = null, StatusValue $status, $httpCode = 0
+       ) {
+               if ( $status->isOK() ) {
+                       throw new InvalidArgumentException( __METHOD__ . ' requires a fatal Status' );
+               }
+
+               $this->modulePath = $module ? $module->getModulePath() : null;
+               $this->status = $status;
+
+               // Bug T46111: Messages in the log files should be in English and not
+               // customized by the local wiki.
+               $enMsg = clone $this->getApiMessage();
+               $enMsg->inLanguage( 'en' )->useDatabase( false );
+               parent::__construct(
+                       ApiErrorFormatter::stripMarkup( $enMsg->text() ),
+                       $enMsg->getApiCode(),
+                       $httpCode,
+                       $enMsg->getApiData()
+               );
+       }
+
+       /**
+        * @param ApiBase|null $module API module responsible for the error, if known
+        * @param string|array|Message $msg See ApiMessage::create()
+        * @param string|null $code See ApiMessage::create()
+        * @param array|null $data See ApiMessage::create()
+        * @param int $httpCode HTTP error code to use
+        * @return static
+        */
+       public static function newWithMessage(
+               ApiBase $module = null, $msg, $code = null, $data = null, $httpCode = 0
+       ) {
+               return new static(
+                       $module,
+                       StatusValue::newFatal( ApiMessage::create( $msg, $code, $data ) ),
+                       $httpCode
+               );
+       }
+
+       /**
+        * @returns ApiMessage
+        */
+       private function getApiMessage() {
+               $errors = $this->status->getErrorsByType( 'error' );
+               if ( !$errors ) {
+                       $errors = $this->status->getErrors();
+               }
+               if ( !$errors ) {
+                       $msg = new ApiMessage( 'apierror-unknownerror-nocode', 'unknownerror' );
+               } else {
+                       $msg = ApiMessage::create( $errors[0] );
+               }
+               return $msg;
+       }
+
+       /**
+        * Fetch the responsible module name
+        * @return string|null
+        */
+       public function getModulePath() {
+               return $this->modulePath;
+       }
+
+       /**
+        * Fetch the error status
+        * @return StatusValue
+        */
+       public function getStatusValue() {
+               return $this->status;
+       }
+
+       /**
+        * @deprecated Do not use. This only exists here because UsageException is in
+        *  the inheritance chain for backwards compatibility.
+        * @inheritdoc
+        */
+       public function getCodeString() {
+               return $this->getApiMessage()->getApiCode();
+       }
+
+       /**
+        * @deprecated Do not use. This only exists here because UsageException is in
+        *  the inheritance chain for backwards compatibility.
+        * @inheritdoc
+        */
+       public function getMessageArray() {
+               $enMsg = clone $this->getApiMessage();
+               $enMsg->inLanguage( 'en' )->useDatabase( false );
+
+               return [
+                       'code' => $enMsg->getApiCode(),
+                       'info' => ApiErrorFormatter::stripMarkup( $enMsg->text() ),
+               ] + $enMsg->getApiData();
+       }
+
+       /**
+        * @return string
+        */
+       public function __toString() {
+               $enMsg = clone $this->getApiMessage();
+               $enMsg->inLanguage( 'en' )->useDatabase( false );
+               $text = ApiErrorFormatter::stripMarkup( $enMsg->text() );
+
+               return get_class( $this ) . ": {$enMsg->getApiCode()}: {$text} "
+                       . "in {$this->getFile()}:{$this->getLine()}\n"
+                       . "Stack trace:\n{$this->getTraceAsString()}";
+       }
+
+}
index 3a7a082..d257e90 100644 (file)
@@ -35,12 +35,10 @@ class ApiWatch extends ApiBase {
        public function execute() {
                $user = $this->getUser();
                if ( !$user->isLoggedIn() ) {
-                       $this->dieUsage( 'You must be logged-in to have a watchlist', 'notloggedin' );
+                       $this->dieWithError( 'watchlistanontext', 'notloggedin' );
                }
 
-               if ( !$user->isAllowed( 'editmywatchlist' ) ) {
-                       $this->dieUsage( 'You don\'t have permission to edit your watchlist', 'permissiondenied' );
-               }
+               $this->checkUserRightsAny( 'editmywatchlist' );
 
                $params = $this->extractRequestParams();
 
@@ -78,16 +76,19 @@ class ApiWatch extends ApiBase {
                        } ) );
 
                        if ( $extraParams ) {
-                               $p = $this->getModulePrefix();
-                               $this->dieUsage(
-                                       "The parameter {$p}title can not be used with " . implode( ', ', $extraParams ),
+                               $this->dieWithError(
+                                       [
+                                               'apierror-invalidparammix-cannotusewith',
+                                               $this->encodeParamName( 'title' ),
+                                               $pageSet->encodeParamName( $extraParams[0] )
+                                       ],
                                        'invalidparammix'
                                );
                        }
 
                        $title = Title::newFromText( $params['title'] );
                        if ( !$title || !$title->isWatchable() ) {
-                               $this->dieUsageMsg( [ 'invalidtitle', $params['title'] ] );
+                               $this->dieWithError( [ 'invalidtitle', $params['title'] ] );
                        }
                        $res = $this->watchTitle( $title, $user, $params, true );
                }
@@ -128,7 +129,11 @@ class ApiWatch extends ApiBase {
                        if ( $compatibilityMode ) {
                                $this->dieStatus( $status );
                        }
-                       $res['error'] = $this->getErrorFromStatus( $status );
+                       $res['errors'] = $this->getErrorFormatter()->arrayFromStatus( $status, 'error' );
+                       $res['warnings'] = $this->getErrorFormatter()->arrayFromStatus( $status, 'warning' );
+                       if ( !$res['warnings'] ) {
+                               unset( $res['warnings'] );
+                       }
                }
 
                return $res;
index 5072c66..03c9f52 100644 (file)
@@ -71,5 +71,6 @@
        "apihelp-query+allrevisions-description": "اعرض كل المراجعات.",
        "apihelp-query+blocks-example-simple": "قائمة المنع.",
        "apihelp-query+imageinfo-paramvalue-prop-userid": "إضافة هوية المستخدم الذي قام بتحميل كل إصدار ملف.",
-       "apihelp-query+prefixsearch-param-offset": "عدد النتائج المراد تخطيها."
+       "apihelp-query+prefixsearch-param-offset": "عدد النتائج المراد تخطيها.",
+       "api-feed-error-title": "خطأ ($1)"
 }
index f1ce435..00aa00d 100644 (file)
        "apihelp-main-param-smaxage": "Den <code>s-maxage</code>-HTTP-Cache-Control-Header auf diese Anzahl Sekunden festlegen. Fehler werden niemals gepuffert.",
        "apihelp-main-param-maxage": "Den <code>max-age</code>-HTTP-Cache-Control-Header auf diese Anzahl Sekunden festlegen. Fehler werden niemals gecacht.",
        "apihelp-main-param-assert": "Sicherstellen, dass der Benutzer eingeloggt ist, wenn auf <kbd>user</kbd> gesetzt, oder Bot ist, wenn auf <kbd>bot</kbd> gesetzt.",
+       "apihelp-main-param-assertuser": "Überprüft, ob der aktuelle Benutzer der benannte Benutzer ist.",
        "apihelp-main-param-requestid": "Der angegebene Wert wird mit in die Antwort aufgenommen und kann zur Unterscheidung von Anfragen verwendet werden.",
        "apihelp-main-param-servedby": "Namen des bearbeitenden Hosts mit zurückgeben.",
        "apihelp-main-param-curtimestamp": "Aktuellen Zeitstempel mit zurückgeben.",
+       "apihelp-main-param-responselanginfo": "Bezieht die für <var>uselang</var> und <var>errorlang</var> verwendeten Sprachen im Ergebnis mit ein.",
        "apihelp-main-param-origin": "Beim Zugriff auf die API mit einer Kreuz-Domain-AJAX-Anfrage (CORS) muss dies als entstehende Domäne festgelegt werden. Dies muss in jeder Vorfluganfrage mit eingeschlossen werden und deshalb ein Teil der Anfragen-URI sein (nicht des POST-Körpers).\n\nFür authentifizierte Anfragen muss dies exakt einem der Ursprünge im Header <code>Origin</code> entsprechen, so dass es auf etwas wie <kbd>https://de.wikipedia.org</kbd> oder <kbd>https://meta.wikimedia.org</kbd> festgelegt werden muss. Falls dieser Parameter nicht mit dem Header <code>Origin</code> übereinstimmt, wird eine 403-Antwort zurückgegeben. Falls dieser Parameter mit dem Header <code>Origin</code> übereinstimmt und der Ursprung weißgelistet ist, werden die Header <code>Access-Control-Allow-Origin</code> und <code>Access-Control-Allow-Credentials</code> festgelegt.\n\nGib für nicht authentifizierte Anfragen den Wert <kbd>*</kbd> an. Dies verursacht, dass der Header <code>Access-Control-Allow-Origin</code> festgelegt wird, aber <code>Access-Control-Allow-Credentials</code> wird <code>false</code> sein und alle benutzerspezifischen Daten werden beschränkt.",
        "apihelp-main-param-uselang": "Zu verwendende Sprache für Nachrichtenübersetzungen. <kbd>[[Special:ApiHelp/query+siteinfo|action=query&meta=siteinfo]]</kbd> mit <kbd>siprop=languages</kbd> gibt eine Liste der Sprachcodes zurück. Gib <kbd>user</kbd> zum Verwenden der aktuellen Benutzerspracheinstellung oder <kbd>content</kbd> an, um die Inhaltssprache des Wikis zu verwenden.",
+       "apihelp-main-param-errorsuselocal": "Falls angegeben, verwenden Fehlertexte lokalisierte Nachrichten aus dem {{ns:MediaWiki}}-Namensraum.",
        "apihelp-block-description": "Einen Benutzer sperren.",
        "apihelp-block-param-user": "Benutzername, IP-Adresse oder IP-Bereich, der gesperrt werden soll.",
        "apihelp-block-param-expiry": "Sperrdauer. Kann relativ (z.&nbsp;B. <kbd>5 months</kbd> oder <kbd>2 weeks</kbd>) oder absolut (z.&nbsp;B. <kbd>2014-09-18T12:34:56Z</kbd>) sein. Wenn auf <kbd>infinite</kbd>, <kbd>indefinite</kbd> oder <kbd>never</kbd> gesetzt, ist die Sperre unbegrenzt.",
        "apihelp-query+allmessages-param-prop": "Zurückzugebende Eigenschaften.",
        "apihelp-query+allmessages-param-enableparser": "Setzen, um den Parser zu aktivieren. Dies wird den Wikitext der Nachricht vorverarbeiten (magische Worte ersetzen, Vorlagen berücksichtigen, usw.).",
        "apihelp-query+allmessages-param-nocontent": "Wenn gesetzt, füge nicht den Inhalt der Nachricht der Ausgabe hinzu.",
-       "apihelp-query+allmessages-param-includelocal": "Schließt auch lokale Nachrichten ein. Zum Beispiel Nachrichten die es nicht in der Software gibt, die es aber als MediaWiki: - Seite gibt. Dies listet alle MediaWiki: - Seiten auf. Daher werden auch diejenigen aufgelistet, die eigentlich keine Nachrichten sind, wie [[MediaWiki:Common.js|Common.js]].",
+       "apihelp-query+allmessages-param-includelocal": "Schließt auch lokale Nachrichten ein, zum Beispiel Nachrichten, die nicht in der Software vorhanden sind, aber dafür im {{ns:MediaWiki}}-Namensraum.\nDies listet alle Seiten im {{ns:MediaWiki}}-Namensraum auf, auch solche, die nicht wirklich Nachrichten sind, wie [[MediaWiki:Common.js|Common.js]].",
        "apihelp-query+allmessages-param-args": "Argumente die in der Nachricht ersetzt werden sollen.",
        "apihelp-query+allmessages-param-filter": "Gebe nur Nachrichten mit Namen, die diese Zeichenfolge enthalten, zurück.",
        "apihelp-query+allmessages-param-customised": "Gebe nur Nachrichten in diesem Anpassungszustand zurück.",
        "apihelp-query+allrevisions-param-generatetitles": "Wenn als Generator verwendet, werden eher Titel als Bearbeitungs-IDs erzeugt.",
        "apihelp-query+allrevisions-example-user": "Liste die letzten 50 Beiträge, sortiert nach Benutzer <kbd>Beispiel</kbd> auf.",
        "apihelp-query+allrevisions-example-ns-main": "Liste die ersten 50 Bearbeitungen im Hauptnamensraum auf.",
+       "apihelp-query+mystashedfiles-paramvalue-prop-size": "Ruft die Dateigröße und Bildabmessungen ab.",
        "apihelp-query+mystashedfiles-param-limit": "Wie viele Dateien zurückgegeben werden sollen.",
        "apihelp-query+alltransclusions-description": "Liste alle Transklusionen auf (eingebettete Seiten die &#123;&#123;x&#125;&#125; benutzen), einschließlich nicht vorhandener.",
        "apihelp-query+alltransclusions-param-from": "Der Titel der Transklusion bei dem die Auflistung beginnen soll.",
        "apihelp-phpfm-description": "Daten im serialisierten PHP-Format ausgeben (schöngedruckt in HTML).",
        "apihelp-rawfm-description": "Daten, einschließlich Fehlerbehebungselementen, im JSON-Format ausgeben (schöngedruckt in HTML).",
        "apihelp-xml-description": "Daten im XML-Format ausgeben.",
-       "apihelp-xml-param-xslt": "Falls angegeben, fügt die benannte Seite als XSL-Stylesheet hinzu. Der Wert muss ein Titel im Namensraum „{{ns:mediawiki}}“ sein und mit <code>.xsl</code> enden.",
+       "apihelp-xml-param-xslt": "Falls angegeben, fügt die benannte Seite als XSL-Stylesheet hinzu. Der Wert muss ein Titel im Namensraum „{{ns:MediaWiki}}“ sein und mit <code>.xsl</code> enden.",
        "apihelp-xml-param-includexmlnamespace": "Falls angegeben, ergänzt einen XML-Namensraum.",
        "apihelp-xmlfm-description": "Daten im XML-Format ausgeben (schöngedruckt in HTML).",
        "api-format-title": "MediaWiki-API-Ergebnis",
index 28cd746..02aa6db 100644 (file)
        "apihelp-main-param-requestid": "Any value given here will be included in the response. May be used to distinguish requests.",
        "apihelp-main-param-servedby": "Include the hostname that served the request in the results.",
        "apihelp-main-param-curtimestamp": "Include the current timestamp in the result.",
+       "apihelp-main-param-responselanginfo": "Include the languages used for <var>uselang</var> and <var>errorlang</var> in the result.",
        "apihelp-main-param-origin": "When accessing the API using a cross-domain AJAX request (CORS), set this to the originating domain. This must be included in any pre-flight request, and therefore must be part of the request URI (not the POST body).\n\nFor authenticated requests, this must match one of the origins in the <code>Origin</code> header exactly, so it has to be set to something like <kbd>https://en.wikipedia.org</kbd> or <kbd>https://meta.wikimedia.org</kbd>. If this parameter does not match the <code>Origin</code> header, a 403 response will be returned. If this parameter matches the <code>Origin</code> header and the origin is whitelisted, the <code>Access-Control-Allow-Origin</code> and <code>Access-Control-Allow-Credentials</code> headers will be set.\n\nFor non-authenticated requests, specify the value <kbd>*</kbd>. This will cause the <code>Access-Control-Allow-Origin</code> header to be set, but <code>Access-Control-Allow-Credentials</code> will be <code>false</code> and all user-specific data will be restricted.",
        "apihelp-main-param-uselang": "Language to use for message translations. <kbd>[[Special:ApiHelp/query+siteinfo|action=query&meta=siteinfo]]</kbd> with <kbd>siprop=languages</kbd> returns a list of language codes, or specify <kbd>user</kbd> to use the current user's language preference, or specify <kbd>content</kbd> to use this wiki's content language.",
+       "apihelp-main-param-errorformat": "Format to use for warning and error text output.\n; plaintext: Wikitext with HTML tags removed and entities replaced.\n; wikitext: Unparsed wikitext.\n; html: HTML.\n; raw: Message key and parameters.\n; none: No text output, only the error codes.\n; bc: Format used prior to MediaWiki 1.29. <var>errorlang</var> and <var>errorsuselocal</var> are ignored.",
+       "apihelp-main-param-errorlang": "Language to use for warnings and errors. <kbd>[[Special:ApiHelp/query+siteinfo|action=query&meta=siteinfo]]</kbd> with <kbd>siprop=languages</kbd> returns a list of language codes, or specify <kbd>content</kbd> to use this wiki's content language, or specify <kbd>uselang</kbd> to use the same value as the <var>uselang</var> parameter.",
+       "apihelp-main-param-errorsuselocal": "If given, error texts will use locally-customized messages from the {{ns:MediaWiki}} namespace.",
 
        "apihelp-block-description": "Block a user.",
        "apihelp-block-param-user": "Username, IP address, or IP address range to block.",
        "apihelp-query+allmessages-param-prop": "Which properties to get.",
        "apihelp-query+allmessages-param-enableparser": "Set to enable parser, will preprocess the wikitext of message (substitute magic words, handle templates, etc.).",
        "apihelp-query+allmessages-param-nocontent": "If set, do not include the content of the messages in the output.",
-       "apihelp-query+allmessages-param-includelocal": "Also include local messages, i.e. messages that don't exist in the software but do exist as a MediaWiki: page.\nThis lists all MediaWiki: pages, so it will also list those that aren't really messages such as [[MediaWiki:Common.js|Common.js]].",
+       "apihelp-query+allmessages-param-includelocal": "Also include local messages, i.e. messages that don't exist in the software but do exist as in the {{ns:MediaWiki}} namespace.\nThis lists all {{ns:MediaWiki}}-namespace pages, so it will also list those that aren't really messages such as [[MediaWiki:Common.js|Common.js]].",
        "apihelp-query+allmessages-param-args": "Arguments to be substituted into message.",
        "apihelp-query+allmessages-param-filter": "Return only messages with names that contain this string.",
        "apihelp-query+allmessages-param-customised": "Return only messages in this customisation state.",
        "apihelp-phpfm-description": "Output data in serialized PHP format (pretty-print in HTML).",
        "apihelp-rawfm-description": "Output data, including debugging elements, in JSON format (pretty-print in HTML).",
        "apihelp-xml-description": "Output data in XML format.",
-       "apihelp-xml-param-xslt": "If specified, adds the named page as an XSL stylesheet. The value must be a title in the {{ns:mediawiki}} namespace ending in <code>.xsl</code>.",
+       "apihelp-xml-param-xslt": "If specified, adds the named page as an XSL stylesheet. The value must be a title in the {{ns:MediaWiki}} namespace ending in <code>.xsl</code>.",
        "apihelp-xml-param-includexmlnamespace": "If specified, adds an XML namespace.",
        "apihelp-xmlfm-description": "Output data in XML format (pretty-print in HTML).",
 
        "api-help-authmanagerhelper-continue": "This request is a continuation after an earlier <samp>UI</samp> or <samp>REDIRECT</samp> response. Either this or <var>$1returnurl</var> is required.",
        "api-help-authmanagerhelper-additional-params": "This module accepts additional parameters depending on the available authentication requests. Use <kbd>[[Special:ApiHelp/query+authmanagerinfo|action=query&meta=authmanagerinfo]]</kbd> with <kbd>amirequestsfor=$1</kbd> (or a previous response from this module, if applicable) to determine the requests available and the fields that they use.",
 
+       "apierror-allimages-redirect": "Use <kbd>gaifilterredir=nonredirects</kbd> instead of <var>redirects</var> when using <kbd>allimages</kbd> as a generator.",
+       "apierror-allpages-generator-redirects": "Use <kbd>gapfilterredir=nonredirects</kbd> instead of <var>redirects</var> when using <kbd>allpages</kbd> as a generator.",
+       "apierror-appendnotsupported": "Can't append to pages using content model $1.",
+       "apierror-articleexists": "The article you tried to create has been created already.",
+       "apierror-assertbotfailed": "Assertion that the user has the <code>bot</code> right failed.",
+       "apierror-assertnameduserfailed": "Assertion that the user is \"$1\" failed.",
+       "apierror-assertuserfailed": "Assertion that the user is logged in failed.",
+       "apierror-autoblocked": "Your IP address has been blocked automatically, because it was used by a blocked user.",
+       "apierror-badconfig-resulttoosmall": "The value of <code>$wgAPIMaxResultSize</code> on this wiki is too small to hold basic result information.",
+       "apierror-badcontinue": "Invalid continue param. You should pass the original value returned by the previous query.",
+       "apierror-baddiff": "The diff cannot be retrieved, one or both revisions do not exist or you do not have permission to view them.",
+       "apierror-baddiffto": "<var>$1diffto</var> must be set to a non-negative number, <kbd>prev</kbd>, <kbd>next</kbd> or <kbd>cur</kbd>.",
+       "apierror-badformat-generic": "The requested format $1 is not supported for content model $2.",
+       "apierror-badformat": "The requested format $1 is not supported for content model $2 used by $3.",
+       "apierror-badgenerator-notgenerator": "Module <kbd>$1</kbd> cannot be used as a generator.",
+       "apierror-badgenerator-unknown": "Unknown <kbd>generator=$1</kbd>.",
+       "apierror-badip": "IP parameter is not valid.",
+       "apierror-badmd5": "The supplied MD5 hash was incorrect.",
+       "apierror-badmodule-badsubmodule": "The module <kbd>$1</kbd> does not have a submodule \"$2\".",
+       "apierror-badmodule-nosubmodules": "The module <kbd>$1</kbd> has no submodules.",
+       "apierror-badparameter": "Invalid value for parameter <var>$1</var>.",
+       "apierror-badquery": "Invalid query.",
+       "apierror-badtimestamp": "Invalid value \"$2\" for timestamp parameter <var>$1</var>.",
+       "apierror-badtoken": "Invalid CSRF token.",
+       "apierror-badupload": "File upload parameter <var>$1</var> is not a file upload; be sure to use <code>multipart/form-data</code> for your POST and include a filename in the <code>Content-Disposition</code> header.",
+       "apierror-badurl": "Invalid value \"$2\" for URL parameter <var>$1</var>.",
+       "apierror-baduser": "Invalid value \"$2\" for user parameter <var>$1</var>.",
+       "apierror-badvalue-notmultivalue": "U+001F multi-value separation may only be used for multi-valued parameters.",
+       "apierror-bad-watchlist-token": "Incorrect watchlist token provided. Please set a correct token in [[Special:Preferences]].",
+       "apierror-blockedfrommail": "You have been blocked from sending email.",
+       "apierror-blocked": "You have been blocked from editing.",
+       "apierror-botsnotsupported": "This interface is not supported for bots.",
+       "apierror-cannotreauthenticate": "This action is not available as your identity cannot be verified.",
+       "apierror-cannotviewtitle": "You are not allowed to view $1.",
+       "apierror-cantblock-email": "You don't have permission to block users from sending email through the wiki.",
+       "apierror-cantblock": "You don't have permission to block users.",
+       "apierror-cantchangecontentmodel": "You don't have permission to change the content model of a page.",
+       "apierror-canthide": "You don't have permission to hide user names from the block log.",
+       "apierror-cantimport-upload": "You don't have permission to import uploaded pages.",
+       "apierror-cantimport": "You don't have permission to import pages.",
+       "apierror-cantoverwrite-sharedfile": "The target file exists on a shared repository and you do not have permission to override it.",
+       "apierror-cantsend": "You are not logged in, you do not have a confirmed email address, or you are not allowed to send email to other users, so you cannot send email.",
+       "apierror-cantundelete": "Couldn't undelete: the requested revisions may not exist, or may have been undeleted already.",
+       "apierror-changeauth-norequest": "Failed to create change request.",
+       "apierror-chunk-too-small": "Minimum chunk size is $1 {{PLURAL:$1|byte|bytes}} for non-final chunks.",
+       "apierror-cidrtoobroad": "$1 CIDR ranges broader than /$2 are not accepted.",
+       "apierror-compare-inputneeded": "A title, a page ID, or a revision number is needed for both the <var>from</var> and the <var>to</var> parameters.",
+       "apierror-contentserializationexception": "Content serialization failed: $1",
+       "apierror-contenttoobig": "The content you supplied exceeds the article size limit of $1 {{PLURAL:$1|kilobyte|kilobytes}}.",
+       "apierror-copyuploadbaddomain": "Uploads by URL are not allowed from this domain.",
+       "apierror-copyuploadbadurl": "Upload not allowed from this URL.",
+       "apierror-create-titleexists": "Existing titles can't be protected with <kbd>create</kbd>.",
+       "apierror-csp-report": "Error processing CSP report: $1.",
+       "apierror-databaseerror": "[$1] Database query error.",
+       "apierror-deletedrevs-param-not-1-2": "The <var>$1</var> parameter cannot be used in modes 1 or 2.",
+       "apierror-deletedrevs-param-not-3": "The <var>$1</var> parameter cannot be used in mode 3.",
+       "apierror-emptynewsection": "Creating empty new sections is not possible.",
+       "apierror-emptypage": "Creating new, empty pages is not allowed.",
+       "apierror-exceptioncaught": "[$1] Exception caught: $2",
+       "apierror-filedoesnotexist": "File does not exist.",
+       "apierror-fileexists-sharedrepo-perm": "The target file exists on a shared repository. Use the <var>ignorewarnings</var> parameter to override it.",
+       "apierror-filenopath": "Cannot get local file path.",
+       "apierror-filetypecannotberotated": "File type cannot be rotated.",
+       "apierror-formatphp": "This response cannot be represented using <kbd>format=php</kbd>. See https://phabricator.wikimedia.org/T68776.",
+       "apierror-imageusage-badtitle": "The title for <kbd>$1</kbd> must be a file.",
+       "apierror-import-unknownerror": "Unknown error on import: $1.",
+       "apierror-integeroutofrange-abovebotmax": "<var>$1</var> may not be over $2 (set to $3) for bots or sysops.",
+       "apierror-integeroutofrange-abovemax": "<var>$1</var> may not be over $2 (set to $3) for users.",
+       "apierror-integeroutofrange-belowminimum": "<var>$1</var> may not be less than $2 (set to $3).",
+       "apierror-invalidcategory": "The category name you entered is not valid.",
+       "apierror-invalid-chunk": "Offset plus current chunk is greater than claimed file size.",
+       "apierror-invalidexpiry": "Invalid expiry time \"$1\".",
+       "apierror-invalid-file-key": "Not a valid file key.",
+       "apierror-invalidlang": "Invalid language code for parameter <var>$1</var>.",
+       "apierror-invalidoldimage": "The oldimage parameter has invalid format.",
+       "apierror-invalidparammix-cannotusewith": "The <kbd>$1</kbd> parameter cannot be used with <kbd>$2</kbd>.",
+       "apierror-invalidparammix-mustusewith": "The <kbd>$1</kbd> parameter may only be used with <kbd>$2</kbd>.",
+       "apierror-invalidparammix-parse-new-section": "<kbd>section=new</kbd> cannot be combined with the <var>oldid</var>, <var>pageid</var> or <var>page</var> parameters. Please use <var>title</var> and <var>text</var>.",
+       "apierror-invalidparammix": "The {{PLURAL:$2|parameters}} $1 can not be used together.",
+       "apierror-invalidsection": "The section parameter must be a valid section ID or <kbd>new</kbd>.",
+       "apierror-invalidsha1base36hash": "The SHA1Base36 hash provided is not valid.",
+       "apierror-invalidsha1hash": "The SHA1 hash provided is not valid.",
+       "apierror-invalidtitle": "Bad title \"$1\".",
+       "apierror-invalidurlparam": "Invalid value for <var>$1urlparam</var> (<kbd>$2=$3</kbd>).",
+       "apierror-invaliduser": "Invalid username \"$1\".",
+       "apierror-maxlag-generic": "Waiting for a database server: $1 {{PLURAL:$1|second|seconds}} lagged.",
+       "apierror-maxlag": "Waiting for $2: $1 {{PLURAL:$1|second|seconds}} lagged.",
+       "apierror-mimesearchdisabled": "MIME search is disabled in Miser Mode.",
+       "apierror-missingcontent-pageid": "Missing content for page ID $1.",
+       "apierror-missingparam-at-least-one-of": "{{PLURAL:$2|The parameter|At least one of the parameters}} $1 is required.",
+       "apierror-missingparam-one-of": "{{PLURAL:$2|The parameter|One of the parameters}} $1 is required.",
+       "apierror-missingparam": "The <var>$1</var> parameter must be set.",
+       "apierror-missingrev-pageid": "No current revision of page ID $1.",
+       "apierror-missingtitle-createonly": "Missing titles can only be protected with <kbd>create</kbd>.",
+       "apierror-missingtitle": "The page you specified doesn't exist.",
+       "apierror-missingtitle-byname": "The page $1 doesn't exist.",
+       "apierror-moduledisabled": "The <kbd>$1</kbd> module has been disabled.",
+       "apierror-multival-only-one-of": "{{PLURAL:$3|Only|Only one of}} $2 is allowed for parameter <var>$1</var>.",
+       "apierror-multival-only-one": "Only one value is allowed for parameter <var>$1</var>.",
+       "apierror-multpages": "<var>$1</var> may only be used with a single page.",
+       "apierror-mustbeloggedin-changeauth": "You must be logged in to change authentication data.",
+       "apierror-mustbeloggedin-generic": "You must be logged in.",
+       "apierror-mustbeloggedin-linkaccounts": "You must be logged in to link accounts.",
+       "apierror-mustbeloggedin-removeauth": "You must be logged in to remove authentication data.",
+       "apierror-mustbeloggedin-uploadstash": "The upload stash is only available to logged-in users.",
+       "apierror-mustbeloggedin": "You must be logged in to $1.",
+       "apierror-mustbeposted": "The <kbd>$1</kbd> module requires a POST request.",
+       "apierror-mustpostparams": "The following {{PLURAL:$2|parameter was|parameters were}} found in the query string, but must be in the POST body: $1.",
+       "apierror-noapiwrite": "Editing of this wiki through the API is disabled. Make sure the <code>$wgEnableWriteAPI=true;</code> statement is included in the wiki's <code>LocalSettings.php</code> file.",
+       "apierror-nochanges": "No changes were requested.",
+       "apierror-nodeleteablefile": "No such old version of the file.",
+       "apierror-no-direct-editing": "Direct editing via API is not supported for content model $1 used by $2.",
+       "apierror-noedit-anon": "Anonymous users can't edit pages.",
+       "apierror-noedit": "You don't have permission to edit pages.",
+       "apierror-noimageredirect-anon": "Anonymous users can't create image redirects.",
+       "apierror-noimageredirect": "You don't have permission to create image redirects.",
+       "apierror-nosuchlogid": "There is no log entry with ID $1.",
+       "apierror-nosuchpageid": "There is no page with ID $1.",
+       "apierror-nosuchrcid": "There is no recent change with ID $1.",
+       "apierror-nosuchrevid": "There is no revision with ID $1.",
+       "apierror-nosuchsection": "There is no section $1.",
+       "apierror-nosuchsection-what": "There is no section $1 in $2.",
+       "apierror-notarget": "You have not specified a valid target for this action.",
+       "apierror-notpatrollable": "The revision r$1 can't be patrolled as it's too old.",
+       "apierror-nouploadmodule": "No upload module set.",
+       "apierror-opensearch-json-warnings": "Warnings cannot be represented in OpenSearch JSON format.",
+       "apierror-pagecannotexist": "Namespace doesn't allow actual pages.",
+       "apierror-pagedeleted": "The page has been deleted since you fetched its timestamp.",
+       "apierror-paramempty": "The parameter <var>$1</var> may not be empty.",
+       "apierror-parsetree-notwikitext": "<kbd>prop=parsetree</kbd> is only supported for wikitext content.",
+       "apierror-parsetree-notwikitext-title": "<kbd>prop=parsetree</kbd> is only supported for wikitext content. $1 uses content model $2.",
+       "apierror-pastexpiry": "Expiry time \"$1\" is in the past.",
+       "apierror-permissiondenied": "You don't have permission to $1.",
+       "apierror-permissiondenied-generic": "Permission denied.",
+       "apierror-permissiondenied-patrolflag": "You need the <code>patrol</code> or <code>patrolmarks</code> right to request the patrolled flag.",
+       "apierror-permissiondenied-unblock": "You don't have permission to unblock users.",
+       "apierror-prefixsearchdisabled": "Prefix search is disabled in Miser Mode.",
+       "apierror-promised-nonwrite-api": "The <code>Promise-Non-Write-API-Action</code> HTTP header cannot be sent to write-mode API modules.",
+       "apierror-protect-invalidaction": "Invalid protection type \"$1\".",
+       "apierror-protect-invalidlevel": "Invalid protection level \"$1\".",
+       "apierror-ratelimited": "You've exceeded your rate limit. Please wait some time and try again.",
+       "apierror-readapidenied": "You need read permission to use this module.",
+       "apierror-readonly": "The wiki is currently in read-only mode.",
+       "apierror-reauthenticate": "You have not authenticated recently in this session, please reauthenticate.",
+       "apierror-redirect-appendonly": "You have attempted to edit using the redirect-following mode, which must be used in conjuction with <kbd>section=new</kbd>, <var>prependtext</var>, or <var>appendtext</var>.",
+       "apierror-revdel-mutuallyexclusive": "The same field cannot be used in both <var>hide</var> and <var>show</var>.",
+       "apierror-revdel-needtarget": "A target title is required for this RevDel type.",
+       "apierror-revdel-paramneeded": "At least one value is required for <var>hide</var> and/or <var>show</var>.",
+       "apierror-revisions-norevids": "The <var>revids</var> parameter may not be used with the list options (<var>$1limit</var>, <var>$1startid</var>, <var>$1endid</var>, <kbd>$1dir=newer</kbd>, <var>$1user</var>, <var>$1excludeuser</var>, <var>$1start</var>, and <var>$1end</var>).",
+       "apierror-revisions-singlepage": "<var>titles</var>, <var>pageids</var> or a generator was used to supply multiple pages, but the <var>$1limit</var>, <var>$1startid</var>, <var>$1endid</var>, <kbd>$1dir=newer</kbd>, <var>$1user</var>, <var>$1excludeuser</var>, <var>$1start</var>, and <var>$1end</var> parameters may only be used on a single page.",
+       "apierror-revwrongpage": "r$1 is not a revision of $2.",
+       "apierror-searchdisabled": "<var>$1</var> search is disabled.",
+       "apierror-sectionreplacefailed": "Could not merge updated section.",
+       "apierror-sectionsnotsupported": "Sections are not supported for content model $1.",
+       "apierror-sectionsnotsupported-what": "Sections are not supported by $1.",
+       "apierror-show": "Incorrect parameter - mutually exclusive values may not be supplied.",
+       "apierror-siteinfo-includealldenied": "Cannot view all servers' info unless <var>$wgShowHostNames</var> is true.",
+       "apierror-sizediffdisabled": "Size difference is disabled in Miser Mode.",
+       "apierror-spamdetected": "Your edit was refused because it contained a spam fragment: <code>$1</code>.",
+       "apierror-specialpage-cantexecute": "You don't have permission to view the results of this special page.",
+       "apierror-stashedfilenotfound": "Could not find the file in the stash: $1.",
+       "apierror-stashedit-missingtext": "No stashed text found with the given hash.",
+       "apierror-stashfailed-complete": "Chunked upload is already completed, check status for details.",
+       "apierror-stashfailed-nosession": "No chunked upload session with this key.",
+       "apierror-stashfilestorage": "Could not store upload in the stash: $1",
+       "apierror-stashnosuchfilekey": "No such filekey: $1.",
+       "apierror-stashpathinvalid": "File key of improper format or otherwise invalid: $1.",
+       "apierror-stashwrongowner": "Wrong owner: $1",
+       "apierror-stashzerolength": "File is of zero length, and could not be stored in the stash: $1.",
+       "apierror-templateexpansion-notwikitext": "Template expansion is only supported for wikitext content. $1 uses content model $2.",
+       "apierror-toofewexpiries": "$1 expiry {{PLURAL:$1|timestamp was|timestamps were}} provided where $2 {{PLURAL:$2|was|were}} needed.",
+       "apierror-unknownaction": "The action specified, <kbd>$1</kbd>, is not recognized.",
+       "apierror-unknownerror-editpage": "Unknown EditPage error: $1.",
+       "apierror-unknownerror-nocode": "Unknown error.",
+       "apierror-unknownerror": "Unknown error: \"$1\".",
+       "apierror-unknownformat": "Unrecognized format \"$1\".",
+       "apierror-unrecognizedparams": "Unrecognized {{PLURAL:$2|parameter|parameters}}: $1.",
+       "apierror-unrecognizedvalue": "Unrecognized value for parameter <var>$1</var>: $2.",
+       "apierror-unsupportedrepo": "Local file repository does not support querying all images.",
+       "apierror-upload-filekeyneeded": "Must supply a <var>filekey</var> when <var>offset</var> is non-zero.",
+       "apierror-upload-filekeynotallowed": "Cannot supply a <var>filekey</var> when <var>offset</var> is 0.",
+       "apierror-upload-inprogress": "Upload from stash already in progress.",
+       "apierror-upload-missingresult": "No result in status data.",
+       "apierror-urlparamnormal": "Could not normalize image parameters for $1.",
+       "apierror-writeapidenied": "You're not allowed to edit this wiki through the API.",
+
+       "apiwarn-alldeletedrevisions-performance": "For better performance when generating titles, set <kbd>$1dir=newer</kbd>.",
+       "apiwarn-badurlparam": "Could not parse <var>$1urlparam</var> for $2. Using only width and height.",
+       "apiwarn-badutf8": "The value passed for <var>$1</var> contains invalid or non-normalized data. Textual data should be valid, NFC-normalized Unicode without C0 control characters other than HT (\\t), LF (\\n), and CR (\\r).",
+       "apiwarn-checktoken-percentencoding": "Check that symbols such as \"+\" in the token are properly percent-encoded in the URL.",
+       "apiwarn-deprecation-deletedrevs": "<kbd>list=deletedrevs</kbd> has been deprecated. Please use <kbd>prop=deletedrevisions</kbd> or <kbd>list=alldeletedrevisions</kbd> instead.",
+       "apiwarn-deprecation-expandtemplates-prop": "Because no values have been specified for the <var>prop</var> parameter, a legacy format has been used for the output. This format is deprecated, and in the future, a default value will be set for the <var>prop</var> parameter, causing the new format to always be used.",
+       "apiwarn-deprecation-httpsexpected": "HTTP used when HTTPS was expected.",
+       "apiwarn-deprecation-login-botpw": "Main-account login via <kbd>action=login</kbd> is deprecated and may stop working without warning. To continue login with <kbd>action=login</kbd>, see [[Special:BotPasswords]]. To safely continue using main-account login, see <kbd>action=clientlogin</kbd>.",
+       "apiwarn-deprecation-login-nobotpw": "Main-account login via <kbd>action=login</kbd> is deprecated and may stop working without warning. To safely log in, see <kbd>action=clientlogin</kbd>.",
+       "apiwarn-deprecation-login-token": "Fetching a token via <kbd>action=login</kbd> is deprecated. Use <kbd>action=query&meta=tokens&type=login</kbd> instead.",
+       "apiwarn-deprecation-parameter": "The parameter <var>$1</var> has been deprecated.",
+       "apiwarn-deprecation-parse-headitems": "<kbd>prop=headitems</kbd> is deprecated since MediaWiki 1.28. Use <kbd>prop=headhtml</kbd> when creating new HTML documents, or <kbd>prop=modules|jsconfigvars</kbd> when updating a document client-side.",
+       "apiwarn-deprecation-purge-get": "Use of <kbd>action=purge</kbd> via GET is deprecated. Use POST instead.",
+       "apiwarn-deprecation-withreplacement": "<kbd>$1</kbd> has been deprecated. Please use <kbd>$2</kbd> instead.",
+       "apiwarn-difftohidden": "Couldn't diff to r$1: content is hidden.",
+       "apiwarn-errorprinterfailed": "Error printer failed. Will retry without params.",
+       "apiwarn-errorprinterfailed-ex": "Error printer failed (will retry without params): $1",
+       "apiwarn-invalidcategory": "\"$1\" is not a category.",
+       "apiwarn-invalidtitle": "\"$1\" is not a valid title.",
+       "apiwarn-invalidxmlstylesheetext": "Stylesheet should have <code>.xsl</code> extension.",
+       "apiwarn-invalidxmlstylesheet": "Invalid or non-existent stylesheet specified.",
+       "apiwarn-invalidxmlstylesheetns": "Stylesheet should be in the {{ns:MediaWiki}} namespace.",
+       "apiwarn-moduleswithoutvars": "Property <kbd>modules</kbd> was set but not <kbd>jsconfigvars</kbd> or <kbd>encodedjsconfigvars</kbd>. Configuration variables are necessary for proper module usage.",
+       "apiwarn-notfile": "\"$1\" is not a file.",
+       "apiwarn-nothumb-noimagehandler": "Could not create thumbnail because $1 does not have an associated image handler.",
+       "apiwarn-parse-nocontentmodel": "No <var>title</var> or <var>contentmodel</var> was given, assuming $1.",
+       "apiwarn-parse-titlewithouttext": "<var>title</var> used without <var>text</var>, and parsed page properties were requested. Did you mean to use <var>page</var> instead of <var>title</var>?",
+       "apiwarn-redirectsandrevids": "Redirect resolution cannot be used together with the <var>revids</var> parameter. Any redirects the <var>revids</var> point to have not been resolved.",
+       "apiwarn-tokennotallowed": "Action \"$1\" is not allowed for the current user.",
+       "apiwarn-tokens-origin": "Tokens may not be obtained when the same-origin policy is not applied.",
+       "apiwarn-toomanyvalues": "Too many values supplied for parameter <var>$1</var>: the limit is $2.",
+       "apiwarn-truncatedresult": "This result was truncated because it would otherwise be larger than the limit of $1 bytes.",
+       "apiwarn-unclearnowtimestamp": "Passing \"$2\" for timestamp parameter <var>$1</var> has been deprecated. If for some reason you need to explicitly specify the current time without calculating it client-side, use <kbd>now<kbd>.",
+       "apiwarn-unrecognizedvalues": "Unrecognized {{PLURAL:$3|value|values}} for parameter <var>$1</var>: $2.",
+       "apiwarn-unsupportedarray": "Parameter <var>$1</var> uses unsupported PHP array syntax.",
+       "apiwarn-urlparamwidth": "Ignoring width value set in <var>$1urlparam</var> ($2) in favor of width value derived from <var>$1urlwidth</var>/<var>$1urlheight</var> ($3).",
+       "apiwarn-validationfailed-badchars": "invalid characters in key (only <code>a-z</code>, <code>A-Z</code>, <code>0-9</code>, <code>_</code>, and <code>-</code> are allowed).",
+       "apiwarn-validationfailed-badpref": "not a valid preference.",
+       "apiwarn-validationfailed-cannotset": "cannot be set by this module.",
+       "apiwarn-validationfailed-keytoolong": "key too long (no more than $1 bytes allowed).",
+       "apiwarn-validationfailed": "Validation error for <kbd>$1</kbd>: $2",
+       "apiwarn-wgDebugAPI": "<strong>Security Warning</strong>: <var>$wgDebugAPI</var> is enabled.",
+
+       "api-feed-error-title": "Error ($1)",
+       "api-usage-docref": "See $1 for API usage.",
+       "api-exception-trace": "$1 at $2($3)\n$4",
        "api-credits-header": "Credits",
        "api-credits": "API developers:\n* Yuri Astrakhan (creator, lead developer Sep 2006–Sep 2007)\n* Roan Kattouw (lead developer Sep 2007–2009)\n* Victor Vasiliev\n* Bryan Tong Minh\n* Sam Reed\n* Brad Jorsch (lead developer 2013–present)\n\nPlease send your comments, suggestions and questions to mediawiki-api@lists.wikimedia.org\nor file a bug report at https://phabricator.wikimedia.org/."
 }
index 1078a6d..99dc57e 100644 (file)
        "apihelp-none-description": "No extraer nada.",
        "apihelp-php-description": "Extraer los datos de salida en formato serializado PHP.",
        "apihelp-rawfm-description": "Extraer los datos de salida, incluidos los elementos de depuración, en formato JSON (embellecido en HTML).",
-       "apihelp-xml-param-xslt": "Si se especifica, añade la página nombrada como una hoja de estilo XSL. El valor debe ser un título en el espacio de nombres {{ns:mediawiki}} que termine en <code>.xsl</code>.",
+       "apihelp-xml-param-xslt": "Si se especifica, añade la página nombrada como una hoja de estilo XSL. El valor debe ser un título en el espacio de nombres {{ns:MediaWiki}} que termine en <code>.xsl</code>.",
        "apihelp-xml-param-includexmlnamespace": "Si se especifica, añade un espacio de nombres XML.",
        "api-help-main-header": "Módulo principal",
        "api-help-flag-deprecated": "Este módulo está en desuso.",
index 9a923c7..9c71082 100644 (file)
        "apihelp-main-param-requestid": "Toute valeur fournie ici sera incluse dans la réponse. Peut être utilisé pour distinguer des demandes.",
        "apihelp-main-param-servedby": "Inclure le nom d’hôte qui a renvoyé la requête dans les résultats.",
        "apihelp-main-param-curtimestamp": "Inclure l’horodatage actuel dans le résultat.",
+       "apihelp-main-param-responselanginfo": "Inclure les langues utilisées pour <var>uselang</var> et <var>errorlang</var> dans le résultat.",
        "apihelp-main-param-origin": "En accédant à l’API en utilisant une requête AJAX inter-domaines (CORS), mettre le domaine d’origine dans ce paramètre. Il doit être inclus dans toute requête de pre-flight, et doit donc faire partie de l’URI de la requête (pas du corps du POST).\n\nPour les requêtes authentifiées, il doit correspondre exactement à une des origines dans l’entête <code>Origin</code> header, donc il doit être fixé avec quelque chose comme <kbd>https://en.wikipedia.org</kbd> ou <kbd>https://meta.wikimedia.org</kbd>. Si ce paramètre ne correspond pas à l’entête <code>Origin</code>, une réponse 403 sera renvoyée. Si ce paramètre correspond à l’entête <code>Origin</code> et que l’origine est en liste blanche, des entêtes <code>Access-Control-Allow-Origin</code> et <code>Access-Control-Allow-Credentials</code> seront positionnés.\n\nPour les requêtes non authentifiées, spécifiez la valeur <kbd>*</kbd>. Cela positionnera l’entête <code>Access-Control-Allow-Origin</code>, mais <code>Access-Control-Allow-Credentials</code> vaudra <code>false</code> et toutes les données spécifiques à l’utilisateur seront filtrées.",
        "apihelp-main-param-uselang": "Langue à utiliser pour les traductions de message. <kbd>[[Special:ApiHelp/query+siteinfo|action=query&meta=siteinfo]]</kbd> avec <kbd>siprop=languages</kbd> renvoie une liste de codes de langue, ou en spécifiant <kbd>user</kbd> pour utiliser la préférence de langue de l’utilisateur actuel, ou en spécifiant <kbd>content</kbd> pour utiliser le langage du contenu de ce wiki.",
+       "apihelp-main-param-errorformat": "Format à utiliser pour la sortie du texte d’avertissement et d’erreur.\n; plaintext: Wikitexte avec balises HTML supprimées et les entités remplacées.\n; wikitext: wikitexte non analysé.\n; html: HTML.\n; raw: Clé de message et paramètres.\n; none: Aucune sortie de texte, uniquement les codes erreur.\n; bc: Format utilisé avant MédiaWiki 1.29. <var>errorlang</var> et <var>errorsuselocal</var> sont ignorés.",
+       "apihelp-main-param-errorlang": "Langue à utiliser pour les avertissements et les erreurs. <kbd>[[Special:ApiHelp/query+siteinfo|action=query&meta=siteinfo]]</kbd> avec <kbd>siprop=languages</kbd> renvoyant une liste de codes de langue, ou spécifier <kbd>content</kbd> pour utiliser la langue du contenu de ce wiki, ou spécifier <kbd>uselang</kbd> pour utiliser la même valeur que le paramètre <var>uselang</var>.",
+       "apihelp-main-param-errorsuselocal": "S’il est fourni, les textes d’erreur utiliseront des messages adaptés à la langue dans l’espace de noms {{ns:MediaWiki}}.",
        "apihelp-block-description": "Bloquer un utilisateur.",
        "apihelp-block-param-user": "Nom d’utilisateur, adresse IP ou plage d’adresses IP que vous voulez bloquer.",
        "apihelp-block-param-expiry": "Durée d’expiration. Peut être relative (par ex. <kbd>5 months</kbd> ou <kbd>2 weeks</kbd>) ou absolue (par ex. <kbd>2014-09-18T12:34:56Z</kbd>). Si elle est mise à <kbd>infinite</kbd>, <kbd>indefinite</kbd> ou <kbd>never</kbd>, le blocage n’expirera jamais.",
        "apihelp-query+allmessages-param-prop": "Quelles propriétés obtenir.",
        "apihelp-query+allmessages-param-enableparser": "Si positionné pour activer l’analyseur, traitera en avance le wikitexte du message (substitution des mots magiques, gestion des modèles, etc.).",
        "apihelp-query+allmessages-param-nocontent": "Si positionné, ne pas inclure le contenu des messages dans la sortie.",
-       "apihelp-query+allmessages-param-includelocal": "Inclure aussi les messages locaux, c’est-à-dire les messages qui n’existent pas dans le logiciel mais sous forme d’une page MediaWiki:.\nCela liste toutes les pages MediaWiki:, donc aussi celles qui ne sont pas vraiment des messages, telles que [[MediaWiki:Common.js|Common.js]].",
+       "apihelp-query+allmessages-param-includelocal": "Inclure aussi les messages locaux, c’est-à-dire les messages qui n’existent pas dans le logiciel mais dans l’espace de noms {{ns:MediaWiki}}.\nCela liste toutes les pages de l’espace de noms {{ns:MediaWiki}}, donc aussi celles qui ne sont pas vraiment des messages, telles que [[MediaWiki:Common.js|Common.js]].",
        "apihelp-query+allmessages-param-args": "Arguments à substituer dans le message.",
        "apihelp-query+allmessages-param-filter": "Renvoyer uniquement les messages avec des noms contenant cette chaîne.",
        "apihelp-query+allmessages-param-customised": "Renvoyer uniquement les messages dans cet état de personnalisation.",
        "apihelp-phpfm-description": "Extraire les données au format sérialisé de PHP (affiché proprement en HTML).",
        "apihelp-rawfm-description": "Extraire les données, y compris les éléments de débogage, au format JSON (affiché proprement en HTML).",
        "apihelp-xml-description": "Extraire les données au format XML.",
-       "apihelp-xml-param-xslt": "Si spécifié, ajoute la page nommée comme une feuille de style XSL. La valeur doit être un titre dans l’espace de noms {{ns:mediawiki}} se terminant par <code>.xsl</code>.",
+       "apihelp-xml-param-xslt": "Si spécifié, ajoute la page nommée comme une feuille de style XSL. La valeur doit être un titre dans l’espace de noms {{ns:MediaWiki}} se terminant par <code>.xsl</code>.",
        "apihelp-xml-param-includexmlnamespace": "Si spécifié, ajoute un espace de noms XML.",
        "apihelp-xmlfm-description": "Extraire les données au format XML (affiché proprement en HTML).",
        "api-format-title": "Résultat de l’API de MediaWiki",
        "api-help-authmanagerhelper-returnurl": "Renvoyer l’URL pour les flux d’authentification tiers, qui doit être absolue. Cela ou <var>$1continue</var> est obligatoire.\n\nDès réception d’une réponse <samp>REDIRECT</samp>, vous ouvrirez typiquement un navigateur ou un affichage web vers l’URL <samp>redirecttarget</samp> spécifiée pour un flux d’authentification tiers. Une fois ceci terminé, le tiers renverra le navigateur ou l’affichage web vers cette URL. Vous devez extraire toute requête ou paramètre POST de l’URL et les passer comme une requête <var>$1continue</var> à ce module de l’API.",
        "api-help-authmanagerhelper-continue": "Cette requête est une continuation après une précédente réponse <samp>UI</samp> ou <samp>REDIRECT</samp>. Cela ou <var>$1returnurl</var> est obligatoire.",
        "api-help-authmanagerhelper-additional-params": "Ce module accepte des paramètres supplémentaires selon les requêtes d’authentification disponibles. Utiliser <kbd>[[Special:ApiHelp/query+authmanagerinfo|action=query&meta=authmanagerinfo]]</kbd> avec <kbd>amirequestsfor=$1</kbd> (ou une réponse précédente de ce module, le cas échéant) pour déterminer les requêtes disponibles et les champs qu’elles utilisent.",
+       "apierror-allimages-redirect": "Utiliser <kbd>gaifilterredir=nonredirects</kbd> au lieu de <var>redirects</var> quand <kbd>allimages</kbd> est utilisé comme générateur.",
+       "apierror-allpages-generator-redirects": "Utiliser <kbd>gapfilterredir=nonredirects</kbd> au lieu de <var>redirects</var> quand <kbd>allpages</kbd> est utilisé comme un générateur.",
+       "apierror-appendnotsupported": "Impossible d’ajouter aux pages utilisant le modèle de contenu $1.",
+       "apierror-articleexists": "L’article que vous essayez de créer l’a déjà été.",
+       "apierror-assertbotfailed": "La vérification que l’utilisateur a le droit <code>bot</code> a échoué.",
+       "apierror-assertnameduserfailed": "La vérification que l’utilisateur est « $1 » a échoué.",
+       "apierror-assertuserfailed": "La vérification que l’utilisateur est connecté a échoué.",
+       "apierror-autoblocked": "Votre adresse IP a été bloquée automatiquement, parce qu’elle a été utilisée par un utilisateur bloqué.",
+       "apierror-badconfig-resulttoosmall": "La valeur de <code>$wgAPIMaxResultSize</code> sur ce wiki est trop petite pour contenir des informations de résultat basiques.",
+       "apierror-badcontinue": "Paramètre de continuation non valide. Vous devez passer la valeur d’origine renvoyée par la requête précédente.",
+       "apierror-baddiff": "La différence ne peut être récupérée, une ou plusieurs révisions n’existent pas ou vous n’avez pas le droit de les voir.",
+       "apierror-baddiffto": "<var>$1diffto</var> doit être fixé à un nombre positif ou nul, <kbd>prev</kbd>, <kbd>next</kbd> ou <kbd>cur</kbd>.",
+       "apierror-badformat-generic": "Le format demandé $1 n’est pas supporté pour le modèle de contenu $2.",
+       "apierror-badformat": "Le format demandé $1 n’est pas supporté pour le modèle de contenu $2 utilisé par $3.",
+       "apierror-badgenerator-notgenerator": "Le module <kbd>$1</kbd> ne peut pas être utilisé comme générateur.",
+       "apierror-badgenerator-unknown": "<kbd>generator=$1</kbd> inconnu.",
+       "apierror-badip": "Paramètre IP non valide.",
+       "apierror-badmd5": "Le hachage MD5 fourni n’était pas correct.",
+       "apierror-badmodule-badsubmodule": "Le module <kbd>$1</kbd> n’a pas de sous-module « $2 ».",
+       "apierror-badmodule-nosubmodules": "Le module <kbd>$1</kbd> n’a pas de sous-modules.",
+       "apierror-badparameter": "Valeur non valide pour le paramètre <var>$1</var>.",
+       "apierror-badquery": "Requête invalide.",
+       "apierror-badtimestamp": "Valeur non valide « $2 » pour le paramètre de référence horaire  <var>$1</var>.",
+       "apierror-badtoken": "Jeton CSRF non valide.",
+       "apierror-badvalue-notmultivalue": "La séparation multi-valeur U+001F ne peut être utilisée que pour des paramètres multi-valeurs.",
        "api-credits-header": "Remerciements",
        "api-credits": "Développeurs de l’API :\n* Roan Kattouw (développeur en chef Sept. 2007–2009)\n* Victor Vasiliev\n* Bryan Tong Minh\n* Sam Reed\n* Yuri Astrakhan (créateur, développeur en chef Sept. 2006–Sept. 2007)\n* Brad Jorsch (développeur en chef depuis 2013)\n\nVeuillez envoyer vos commentaires, suggestions et questions à mediawiki-api@lists.wikimedia.org\nou remplir un rapport de bogue sur https://phabricator.wikimedia.org/."
 }
index 69fdf56..e688f8f 100644 (file)
        "apihelp-query+allmessages-param-prop": "Que propiedades obter.",
        "apihelp-query+allmessages-param-enableparser": "Marcar para activar o analizador, isto preprocesará o texto wiki da mensaxe (substituir palabras máxicas, xestionar modelo, etc.)",
        "apihelp-query+allmessages-param-nocontent": "Se se marca, non inclúe o contido das mensaxes na saída.",
-       "apihelp-query+allmessages-param-includelocal": "Tamén inclúe mensaxes locais, p.ex. mensaxes que non existen no software pero existen como unha páxina MediaWiki:. \nIsto lista todas as páxinas MediaWiki:, polo que tamén listará as que non son realmente mensaxes como [[MediaWiki:Common.js|Common.js]].",
+       "apihelp-query+allmessages-param-includelocal": "Tamén inclúe mensaxes locais, p.ex. mensaxes que non existen no software pero existen como no espazo de nomes {{ns:MediaWiki}}. \nIsto lista todas as páxinas do espazo de nomes {{ns:MediaWiki}}, polo que tamén listará as que non son realmente mensaxes como [[MediaWiki:Common.js|Common.js]].",
        "apihelp-query+allmessages-param-args": "Argumentos a substituír na mensaxe.",
        "apihelp-query+allmessages-param-filter": "Retornar só mensaxes con nomes que conteñan esta cadea.",
        "apihelp-query+allmessages-param-customised": "Devolver só mensaxes neste estado de personalización.",
        "apihelp-phpfm-description": "Datos de saída en formato serializado de PHP(impresión en HTML).",
        "apihelp-rawfm-description": "Datos de saída, incluíndo os elementos de depuración, en formato JSON (impresión en HTML).",
        "apihelp-xml-description": "Datos de saída en formato XML.",
-       "apihelp-xml-param-xslt": "Se está indicado, engade o nome da páxina como unha folla de estilo XSL. O valor debe ser un título no espazo de nomes {{ns:mediawiki}} rematando con <code>.xsl</code>.",
+       "apihelp-xml-param-xslt": "Se está indicado, engade o nome da páxina como unha folla de estilo XSL. O valor debe ser un título no espazo de nomes {{ns:MediaWiki}} rematando con <code>.xsl</code>.",
        "apihelp-xml-param-includexmlnamespace": "Se está indicado, engade un espazo de nomes XML.",
        "apihelp-xmlfm-description": "Datos de saída en formato XML(impresión en HTML).",
        "api-format-title": "Resultado de API de MediaWiki",
        "api-help-authmanagerhelper-returnurl": "Devolve o URL para os fluxos de autenticación de terceiros, que debe ser absoluto. Este ou <var>$1continue</var> é obrigatorio.\n\nLogo da recepción dunha resposta <samp>REDIRECT</samp>, vostede normalmente abrirá un navegador web ou un visor web para ver a URL <samp>redirecttarget</samp> especificada para un fluxo de autenticación de terceiros. Cando isto se complete, a aplicación de terceiros enviará ó navegador web ou visor web a esta URL. Vostede debe eliminar calquera consulta ou parámetros POST da URL e pasalos como unha consulta <var>$1continue</var> a este módulo API.",
        "api-help-authmanagerhelper-continue": "Esta petición é unha continucación despois dun resposta precedente <samp>UI</samp> ou <samp>REDIRECT</samp>. Esta ou <var>$1returnurl</var> é requirida.",
        "api-help-authmanagerhelper-additional-params": "Este módulo acepta parámetros adicionais dependendo das consultas de autenticación dispoñibles. Use <kbd>[[Special:ApiHelp/query+authmanagerinfo|action=query&meta=authmanagerinfo]]</kbd> con <kbd>amirequestsfor=$1</kbd> (ou unha resposta previa deste módulo, se aplicable) para determinar as consultas dispoñibles e os campos que usan.",
+       "apierror-badquery": "A consulta non é válida.",
+       "apierror-blocked": "Foi bloqueado fronte á edición.",
+       "apierror-botsnotsupported": "Esta interface non está dispoñible para bots.",
+       "apierror-cantblock": "Non ten permisos para bloquear usuarios.",
+       "apierror-cantimport": "Non ten permisos para importar páxinas.",
+       "apierror-filedoesnotexist": "O ficheiro non existe.",
+       "apierror-noedit-anon": "Os usuarios anónimos non poden editar páxinas.",
+       "apierror-noedit": "Non ten permisos para editar páxinas.",
+       "apierror-permissiondenied-generic": "Permisos rexeitados.",
+       "apierror-unknownerror-nocode": "Erro descoñecido.",
+       "apierror-unknownerror": "Erro descoñecido: \"$1\".",
+       "apierror-unknownformat": "Formato descoñecido \"$1\".",
+       "apiwarn-invalidcategory": "\"$1\" non é unha categoría.",
+       "apiwarn-invalidtitle": "\"$1\" non é un título válido.",
+       "apiwarn-notfile": "\"$1\" non é un ficheiro.",
+       "api-feed-error-title": "Erro ($1)",
+       "api-usage-docref": "Consulte $1 para ver o uso da API.",
+       "api-exception-trace": "$1 en $2($3)\n$4",
        "api-credits-header": "Créditos",
        "api-credits": "Desenvolvedores da API:\n* Roan Kattouw (desenvolvedor principal, set. 2007-2009)\n* Victor Vasiliev\n* Bryan Tong Minh\n* Sam Reed\n* Yuri Astrakhan (creador e desenvolvedor principal, set. 2006-sep. 2007)\n* Brad Jorsch (desenvolvedor principal, 2013-actualidade)\n\nEnvía comentarios, suxerencias e preguntas a mediawiki-api@lists.wikimedia.org\nou informa dun erro en https://phabricator.wikimedia.org/."
 }
index 52b28d6..3e4e4ce 100644 (file)
        "apihelp-query+allmessages-param-prop": "אלו מאפיינים לקבל.",
        "apihelp-query+allmessages-param-enableparser": "יש להגדיר כדי להפעיל את המפענח, יעשה קדם־עיבוד לקוד ויקי של ההודעה (יחליף מילות קסם, יטפל בתבניות, וכו').",
        "apihelp-query+allmessages-param-nocontent": "אם זה מוגדר, לא לכלול את תוכן ההודעות בפלט.",
-       "apihelp-query+allmessages-param-includelocal": "×\9c×\9b×\9c×\95×\9c ×\92×\9d ×\94×\95×\93×¢×\95ת ×\9eק×\95×\9e×\99×\95ת, ×\9b×\9c×\95×\9eר ×\94×\95×\93×¢×\95ת ×©×\90×\99× ×\9f ×§×\99×\99×\9e×\95ת ×\91ת×\9b× ×\94, ×\90×\91×\9c ×\9b×\9f ×§×\99×\99×\9e×\95ת ×\91ת×\95ר ×\93×£ ×\9e×\93×\99×\94Ö¾×\95×\99ק×\99.\n×\96×\94 ×¨×\95ש×\9d ×\90ת ×\9b×\9c ×\93פ×\99 MediaWiki: כך שזה ירשום גם דפים שאינם באמת הודעות, כגון [[MediaWiki:Common.js|Common.js]].",
+       "apihelp-query+allmessages-param-includelocal": "×\9c×\9b×\9c×\95×\9c ×\92×\9d ×\94×\95×\93×¢×\95ת ×\9eק×\95×\9e×\99×\95ת, ×\9b×\9c×\95×\9eר ×\94×\95×\93×¢×\95ת ×©×\90×\99× ×\9f ×§×\99×\99×\9e×\95ת ×\91ת×\9b× ×\94, ×\90×\91×\9c ×\9b×\9f ×§×\99×\99×\9e×\95ת ×\91×\9eר×\97×\91 {{ns:MediaWiki}}.\n×\96×\94 ×¨×\95ש×\9d ×\90ת ×\9b×\9c ×\94×\93פ×\99×\9d ×\91×\9eר×\97×\91 {{ns:MediaWiki}}, כך שזה ירשום גם דפים שאינם באמת הודעות, כגון [[MediaWiki:Common.js|Common.js]].",
        "apihelp-query+allmessages-param-args": "ארגומנטים שיוחלפו לתוך ההודעה.",
        "apihelp-query+allmessages-param-filter": "החזרה רק של הודעות עם שמות שמכילים את המחרוזת הזאת.",
        "apihelp-query+allmessages-param-customised": "להחזיר רק הודעות במצב ההתאמה הזה.",
        "apihelp-phpfm-description": "לפלוט נתונים בתסדיר PHP מוסדר (עם הדפסה יפה ב־HTML).",
        "apihelp-rawfm-description": "לפלוט את הנתונים, כולל אלמנטים לניפוי שגיאות, בתסדיר JSON (עם הדפסה יפה ב־HTML).",
        "apihelp-xml-description": "לפלוט נתונים בתסדיר XML.",
-       "apihelp-xml-param-xslt": "אם צוין, יש להוסיף את שם הדף כגיליון עיצוב XSL. על הערך להיות כותרת ב {{ns:mediawiki}} במרחב שם המשתמש, המסתיים ב-  <code>.xsl</code>.",
+       "apihelp-xml-param-xslt": "אם צוין, יש להוסיף את שם הדף כגיליון עיצוב XSL. על הערך להיות כותרת ב {{ns:MediaWiki}} במרחב שם המשתמש, המסתיים ב-  <code>.xsl</code>.",
        "apihelp-xml-param-includexmlnamespace": "אם זה צוין, מוסיף מרחב שם של XML.",
        "apihelp-xmlfm-description": "לפלוט נתונים בתסדיר XML (עם הדפסה יפה ב־HTML).",
        "api-format-title": "תוצאה של API של מדיה־ויקי",
index e0920f6..232386e 100644 (file)
@@ -92,5 +92,6 @@
        "api-help-param-limit2": "Nem engedélyezett több mint $1 (botoknak $2).",
        "api-help-param-integer-min": "Az {{PLURAL:$1|1=érték nem lehet kisebb|2=értékek nem lehetnek kisebbek}} mint $2.",
        "api-help-param-integer-max": "Az {{PLURAL:$1|1=érték nem lehet nagyobb|2=értékek nem lehetnek nagyobbak}} mint $3.",
-       "api-help-param-integer-minmax": "{{PLURAL:$1|1=Az értéknek $2 és $3 között kell lennie.|2=Az értékeknek $2 és $3 között kell lenniük.}}"
+       "api-help-param-integer-minmax": "{{PLURAL:$1|1=Az értéknek $2 és $3 között kell lennie.|2=Az értékeknek $2 és $3 között kell lenniük.}}",
+       "api-help-param-default": "Alapértelmezett: $1"
 }
index b585885..5ae3547 100644 (file)
@@ -61,7 +61,7 @@
        "apihelp-edit-param-tags": "Ganti tag untuk menerapkan ke revisi.",
        "apihelp-edit-param-minor": "Suntingan kecil.",
        "apihelp-edit-param-notminor": "Bukan suntingan kecil.",
-       "apihelp-edit-param-bot": "Tandai suntingan ini sebagai bot.",
+       "apihelp-edit-param-bot": "Tandai suntingan ini sebagai suntingan bot.",
        "apihelp-edit-param-basetimestamp": "Stempel waktu dari revisi asal, digunakan untuk mendeteksi konflik penyuntingan. Dapat ditemukan di [[Special:ApiHelp/query+revisions|action=query&prop=revisions&rvprop=timestamp]].",
        "apihelp-edit-param-starttimestamp": "Stempel waktu ketika proses penyuntingan dimulai, digunakan untuk mendeteksi konflik penyuntingan. Nilai yang cocok dapat ditemukan dengan menggunakan <var>[[Special:ApiHelp/main|curtimestamp]]</var> ketika memulai proses penyuntingan (seperti ketika memuat isi konten yang akan disunting).",
        "apihelp-edit-param-recreate": "Batalkan galat yang terjadi tentang halaman yang sudah dihapus pada saat itu.",
        "apihelp-emailuser-param-subject": "Tajuk subjek.",
        "apihelp-emailuser-param-text": "Badan pesan.",
        "apihelp-emailuser-param-ccme": "Kirimkan salinan pesan ini kepada saya.",
-       "apihelp-expandtemplates-description": "Tambahkan semua templat dalam teks wiki.",
+       "apihelp-expandtemplates-description": "Longgarkan semua templat dalam teks wiki.",
        "apihelp-expandtemplates-param-title": "Judul halaman.",
        "apihelp-expandtemplates-param-text": "Teks wiki yang akan diubah.",
        "apihelp-expandtemplates-param-revid": "ID revisi, untuk <nowiki>{{REVISIONID}}</nowiki> dan variabel serupa.",
        "apihelp-expandtemplates-param-prop": "Bagian informasi manakah yang ingin didapatkan.\n\nPerhatikan bahwa jika tidak ada nilai yang dipilih, hasilnya akan mengandung teks wiki, namun keluaran akan berupa format usang.",
+       "apihelp-feedcontributions-param-deletedonly": "Tampilkan hanya kontribusi terhapus.",
        "apihelp-login-example-login": "Masuk log.",
+       "apihelp-move-param-noredirect": "Jangan buat pengalihan.",
+       "apihelp-move-param-unwatch": "Hapus halaman dan pengalihan dari daftar pantauan pengguna ini.",
+       "apihelp-move-example-move": "Pindahkan <kbd>Judul buruk</kbd> ke <kbd>Judul benar</kbd> tanpa membuat pengalihan.",
+       "apihelp-opensearch-param-redirects": "Bagaimana menangani pengalihan:\n;return:Kembali ke pengalihan itu.\n;resolve:Kembali ke halaman tujuan. Mungkin hasil kembali kurang dari $1limit.\nUntuk alasan riwayat, nilai baku adalah \"kembali\" untuk $1format=json dan \"resolve\" untuk format lain.",
        "apihelp-query+prefixsearch-param-profile": "Cari profil untuk digunakan.",
        "apihelp-query+search-param-qiprofile": "Meminta profil independen untuk digunakan (berefek pada algoritma peringkat).",
        "apihelp-revisiondelete-param-ids": "Penanda untuk perubahan yang akan dihapus",
index d9d079b..63865ed 100644 (file)
        "apihelp-phpfm-description": "データを PHP のシリアル化した形式 (HTML に埋め込んだ形式) で出力します。",
        "apihelp-rawfm-description": "データをデバッグ要素付きで JSON 形式 (HTML に埋め込んだ形式) で出力します。",
        "apihelp-xml-description": "データを XML 形式で出力します。",
-       "apihelp-xml-param-xslt": "指定すると、XSLスタイルシートとして名付けられたページを追加します。値は、必ず、{{ns:mediawiki}} 名前空間の、ページ名の末尾が <code>.xsl</code> でのタイトルである必要があります。",
+       "apihelp-xml-param-xslt": "指定すると、XSLスタイルシートとして名付けられたページを追加します。値は、必ず、{{ns:MediaWiki}} 名前空間の、ページ名の末尾が <code>.xsl</code> でのタイトルである必要があります。",
        "apihelp-xml-param-includexmlnamespace": "指定すると、XML 名前空間を追加します。",
        "apihelp-xmlfm-description": "データを XML 形式 (HTML に埋め込んだ形式) で出力します。",
        "api-format-title": "MediaWiki API の結果",
index e4e6e8c..98a41d4 100644 (file)
        "apihelp-feedrecentchanges-param-invert": "선택한 항목을 제외한 모든 이름공간.",
        "apihelp-feedrecentchanges-param-associated": "관련 (토론 또는 일반) 이름공간을 포함합니다.",
        "apihelp-feedrecentchanges-param-limit": "반환할 결과의 최대 수.",
-       "apihelp-feedrecentchanges-param-from": "이후의 변경 사항을 보여줍니다.",
+       "apihelp-feedrecentchanges-param-from": "이후의 변경사항을 보여줍니다.",
        "apihelp-feedrecentchanges-param-hideminor": "사소한 편집을 숨깁니다.",
        "apihelp-feedrecentchanges-param-hidebots": "봇의 편집을 숨깁니다.",
        "apihelp-feedrecentchanges-param-hideanons": "익명 사용자의 편집을 숨깁니다.",
        "apihelp-query+users-example-simple": "사용자 <kbd>Example</kbd>의 정보를 반환합니다.",
        "apihelp-query+watchlist-description": "현재 사용자의 주시목록의 문서의 최근 바뀜을 가져옵니다.",
        "apihelp-query+watchlist-param-user": "이 사용자의 변경 사항만 나열합니다.",
-       "apihelp-query+watchlist-param-excludeuser": "이 사용자의 변경 사항을 나열하지 않습니다.",
+       "apihelp-query+watchlist-param-excludeuser": "이 사용자의 변경사항을 나열하지 않습니다.",
        "apihelp-query+watchlist-paramvalue-prop-ids": "판 ID와 페이지 ID를 추가합니다.",
        "apihelp-query+watchlist-paramvalue-prop-title": "문서의 제목을 추가합니다.",
        "apihelp-query+watchlist-paramvalue-prop-flags": "편집에 대한 플래그를 추가합니다.",
        "api-help-right-apihighlimits": "API 쿼리에서 더 높은 제한 사용 (느린 쿼리: $1, 빠른 쿼리: $2) 느린 쿼리에 대한 제한은 다중값 매개변수에도 적용됩니다.",
        "api-help-open-in-apisandbox": "<small>[연습장에서 열기]</small>",
        "api-help-authmanagerhelper-messageformat": "반환 메시지에 사용할 형식.",
+       "apierror-articleexists": "작성하려는 문서가 이미 만들어져 있습니다.",
+       "apierror-badgenerator-unknown": "알 수 없는 <kbd>generator=$1</kbd>.",
+       "apierror-badip": "IP 변수가 유효하지 않습니다.",
+       "apierror-badmodule-nosubmodules": "<kbd>$1</kbd> 모듈은 하위 모듈이 없습니다.",
+       "apierror-badquery": "유효하지 않은 쿼리입니다.",
+       "apierror-badtoken": "잘못된 CSRF 토큰.",
+       "apierror-botsnotsupported": "이 인터페이스는 봇을 위해 지원되지 않습니다.",
+       "apierror-cannotviewtitle": "$1을(를) 볼 권한이 없습니다.",
+       "apierror-cantimport-upload": "업로드된 페이지를 가져올 권한이 없습니다.",
+       "apierror-databaseerror": "[$1] 데이터베이스 쿼리 오류.",
+       "apierror-filedoesnotexist": "파일이 존재하지 않습니다.",
+       "apierror-filenopath": "로컬 파일 경로를 가져올 수 없습니다.",
+       "apierror-invalidcategory": "입력한 분류 이름이 올바르지 않습니다.",
+       "apierror-invalid-file-key": "유효한 파일 키가 아닙니다.",
+       "apierror-invalidtitle": "잘못된 제목 \"$1\".",
+       "apierror-invaliduser": "잘못된 사용자 이름 \"$1\".",
+       "apierror-missingparam": "<var>$1</var> 변수는 설정해야 합니다.",
+       "apierror-missingtitle": "지정한 페이지가 존재하지 않습니다.",
+       "apierror-missingtitle-byname": "$1 문서가 존재하지 않습니다.",
+       "apierror-mustbeloggedin-generic": "로그인해야 합니다.",
+       "apierror-mustbeloggedin-linkaccounts": "계정을 연결하려면 로그인해야 합니다.",
+       "apierror-mustbeloggedin": "$1에 로그인해야 합니다.",
+       "apierror-noedit-anon": "익명 사용자는 문서를 편집할 수 없습니다.",
+       "apierror-readonly": "위키는 현재 읽기 전용 모드입니다.",
+       "apierror-revwrongpage": "r$1은(는) $2의 판이 아닙니다.",
+       "apierror-unknownerror-nocode": "알 수 없는 오류.",
+       "apierror-unknownerror": "알 수 없는 오류: \"$1\"",
+       "apierror-writeapidenied": "API를 통해 이 위키를 편집할 권한이 없습니다.",
+       "apiwarn-difftohidden": "r$1에 대한 차이를 만들 수 없습니다: 내용이 숨겨져 있습니다.",
+       "apiwarn-invalidcategory": "\"$1\"은(는) 분류가 아닙니다.",
+       "apiwarn-invalidtitle": "\"$1\"은(는) 올바른 제목이 아닙니다.",
+       "apiwarn-notfile": "\"$1\"은(는) 파일이 아닙니다.",
+       "api-feed-error-title": "오류 ($1)",
        "api-credits": "API 개발자:\n* Yuri Astrakhan (만든이, 선임 개발자 2006년 9월~2007년 9월)\n* Roan Kattouw (선임 개발자, 2007년 9월–2009년)\n* Victor Vasiliev\n* Bryan Tong Minh\n* Sam Reed\n* Brad Jorsch (선임 개발자 2013년–현재)\n\n당신의 의견이나 제안, 질문은 mediawiki-api@lists.wikimedia.org 로 보내주시고,\n버그 보고는 https://phabricator.wikimedia.org/ 에 해주시기 바랍니다."
 }
index 47b79ab..7d5d0e8 100644 (file)
        "api-help-param-type-user": "Typ: {{PLURAL:$1|1=Benotzernumm|2=Lëscht vu Benotzernimm}}",
        "api-help-examples": "{{PLURAL:$1|Beispill|Beispiler}}:",
        "api-help-permissions": "{{PLURAL:$1|Autorisatioun|Autorisatiounen}}:",
-       "api-help-open-in-apisandbox": "<small>[an der Sandkëscht opmaachen]</small>"
+       "api-help-open-in-apisandbox": "<small>[an der Sandkëscht opmaachen]</small>",
+       "apierror-articleexists": "Den Artikel deen dir probéiert hutt unzeleeë gouf schonn ugeluecht.",
+       "apierror-autoblocked": "Är IP-Adress gouf automatesch gespaart well se vun engem gespaarte Benotzer benotzt gouf.",
+       "apierror-copyuploadbadurl": "D'Eroplueden ass vun dëser URL net erlaabt.",
+       "apierror-import-unknownerror": "Onbekannte Feeler beim Import: $1\nf",
+       "apierror-invalidtitle": "Schlechten Titel \"$1\".",
+       "apierror-missingtitle": "D'Säit déi Dir spezifizéiert hutt gëtt et net.",
+       "apierror-missingtitle-byname": "D'Säit $1 gëtt et net.",
+       "apierror-unknownerror-nocode": "Onbekannte Feeler.",
+       "apierror-writeapidenied": "Dir däerft dës Wiki net iwwer den API ännneren.",
+       "apiwarn-invalidcategory": "\"$1\" ass keng Kategorie.",
+       "apiwarn-invalidtitle": "\"$1\" ass kee valabelen Titel",
+       "apiwarn-tokennotallowed": "Aktioun \"$1\" ass net erlaabt fir den aktuelle Benotzer.",
+       "apiwarn-validationfailed-badpref": "keng valabel Astellung",
+       "api-feed-error-title": "Feeler ($1)"
 }
index 8240e08..b1a2280 100644 (file)
        "apihelp-phpfm-description": "Давај го изводот во серијализиран PHP-формат (подобрен испис во HTML).",
        "apihelp-rawfm-description": "Давај го изводот со елементи за отстранување грешки во JSON-формат (подобрен испис во HTML).",
        "apihelp-xml-description": "Давај го изводот во XML-формат.",
-       "apihelp-xml-param-xslt": "Ако е укажано, ја додава именуваната страница како XSL-стилска страница. Вредноста мора да биде наслов во именскиот простор „{{ns:mediawiki}}“ што ќе завршува со <code>.xsl</code>.",
+       "apihelp-xml-param-xslt": "Ако е укажано, ја додава именуваната страница како XSL-стилска страница. Вредноста мора да биде наслов во именскиот простор „{{ns:MediaWiki}}“ што ќе завршува со <code>.xsl</code>.",
        "apihelp-xml-param-includexmlnamespace": "Ако е укажано, додава именски простор XML.",
        "apihelp-xmlfm-description": "Давај го изводот во XML-формат (подобрен испис во HTML).",
        "api-format-title": "Резултат од Извршникот на МедијаВики",
index f1b4cfe..8ebf223 100644 (file)
@@ -5,7 +5,8 @@
                        "Chameleon222",
                        "Macofe",
                        "Jon Harald Søby",
-                       "Event"
+                       "Event",
+                       "Kingu"
                ]
        },
        "apihelp-main-description": "<div class=\"hlist plainlinks api-main-links\">\n* [[mw:API:Main_page|Dokumentasjon]]\n* [[mw:API:FAQ|Ofte stilte spørsmål]]\n* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-api E-post-liste]\n* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-api-announce API-kunngjøringer]\n* [https://phabricator.wikimedia.org/maniphest/query/GebfyV4uCaLd/#R Feil & forespørsler]\n</div>\n<strong>Status:</strong> Alle funksjonene som vises på denne siden skal virke, men API-en er fortsatt i aktiv utvikling, og kan bli endret når som helst. Abonner på [https://lists.wikimedia.org/pipermail/mediawiki-api-announce/ MediaWiki sin API-kunnkjøringsepostliste] for nyheter om oppdateringer.\n\n<strong>Feile kall:</strong> Hvis det blir sendt feile kall til API-et, blir det sendt en HTTP-header med nøkkelen \"MediaWiki-API-Error\" og da blir både header-verdien og feilkoden sendt tilbake med samme verdi. For mer informasjon se [[mw:API:Errors_and_warnings|API: Feil og advarsler]].\n\n<strong>Testing:</strong> For enkelt å teste API-kall, se [[Special:ApiSandbox]].",
        "api-help-flag-generator": "Denne modulen kan brukes som en generator.",
        "api-help-parameters": "{{PLURAL:$1|Parameter|Parametre}}:",
        "api-help-param-deprecated": "Utgått.",
-       "api-help-param-required": "Denne parameteren er påkrevd."
+       "api-help-param-required": "Denne parameteren er påkrevd.",
+       "apierror-multival-only-one": "Bare én verdi er tillatt for parameteret <var>$1</var>.",
+       "apierror-permissiondenied-generic": "Tilgang nektet.",
+       "apiwarn-validationfailed": "Bekreftelsesfeil <kbd>$1</kbd>: $2"
 }
index 7ba3854..573c3f8 100644 (file)
        "api-help-permissions-granted-to": "{{PLURAL:$1|Przydzielone dla}}: $2",
        "api-help-right-apihighlimits": "Użyj wyższych limitów w zapytaniach API (dla zapytań powolnych: $1; dla zapytań szbkich: $2). Limity zapytań powolnych są także stosowane dla parametrów z podanymi wieloma wartościami.",
        "api-help-open-in-apisandbox": "<small>[otwórz w brudnopisie]</small>",
+       "apierror-badgenerator-unknown": "Nieznany <kbd>generator=$1</kbd>.",
+       "apierror-badip": "Parametr IP nie jest prawidłowy.",
+       "apierror-badquery": "Nieprawidłowe zapytanie.",
+       "apierror-blockedfrommail": "Została Ci zablokowana możliwość wysyłania e-maili.",
+       "apierror-blocked": "Została Ci zablokowana możliwość edycji.",
+       "apierror-cantblock": "Nie masz uprawnień do blokowania użytkowników.",
+       "apierror-cantimport": "Nie masz uprawnień do importowania stron.",
+       "apierror-cantsend": "Nie jesteś zalogowany, nie masz potwierdzonego adresu e-mail, albo nie masz prawa wysyłać e-maili do innych użytkowników, więc nie możesz wysłać wiadomości e-mail.",
+       "apierror-filedoesnotexist": "Plik nie istnieje.",
+       "apierror-integeroutofrange-abovebotmax": "Wartość <var>$1</var> dla botów i administratorów nie może przekraczać $2 (ustawiono $3).",
+       "apierror-integeroutofrange-abovemax": "Wartość <var>$1</var> dla użytkowników nie może przekraczać $2 (ustawiono $3).",
+       "apierror-integeroutofrange-belowminimum": "Wartość <var>$1</var> nie może być mniejsza niż $2 (ustawiono $3).",
+       "apierror-invalidlang": "Nieprawidłowy kod języka dla parametru <var>$1</var>.",
+       "apierror-invalidparammix": "{{PLURAL:$2|Parametry}} $1 nie mogą być używane razem.",
+       "apierror-invalidtitle": "Zły tytuł „$1”.",
+       "apierror-invalidurlparam": "Nieprawidłowa wartość <var>$1urlparam</var> (<kbd>$2=$3</kbd>).",
+       "apierror-missingparam": "Parametr <var>$1</var> musi być podany.",
+       "apierror-missingtitle": "Wybrana przez ciebie strona nie istnieje.",
+       "apierror-missingtitle-byname": "Strona $1 nie istnieje.",
+       "apierror-moduledisabled": "Moduł <kbd>$1</kbd> został wyłączony.",
+       "apierror-mustbeloggedin-generic": "Musisz być zalogowany.",
+       "apierror-noedit-anon": "Niezarejestrowani użytkownicy nie mogą edytować stron.",
+       "apierror-noedit": "Nie masz uprawnień do edytowania stron.",
+       "apierror-permissiondenied": "Nie masz uprawnień do $1.",
+       "apierror-permissiondenied-generic": "Brak dostępu.",
+       "apierror-permissiondenied-unblock": "Nie masz uprawnień do odblokowania użytkowników.",
+       "apierror-protect-invalidaction": "Nieprawidłowy rodzaj zabezpieczenia „$1”.",
+       "apierror-protect-invalidlevel": "Nieprawidłowy poziom zabezpieczeń „$1”.",
+       "apierror-specialpage-cantexecute": "Nie masz uprawnień, aby zobaczyć wyniki tej strony specjalnej.",
+       "apierror-stashwrongowner": "Nieprawidłowy właściciel: $1",
+       "apierror-unknownerror-nocode": "Nieznany błąd.",
+       "apierror-unknownerror": "Nieznany błąd: „$1”.",
+       "apierror-unknownformat": "Nierozpoznany format „$1”.",
+       "apierror-unrecognizedvalue": "Nierozpoznana wartość parametru <var>$1</var>: $2.",
+       "apiwarn-invalidcategory": "„$1” nie jest kategorią.",
+       "apiwarn-invalidtitle": "„$1” nie jest poprawnym tytułem.",
+       "apiwarn-notfile": "„$1” nie jest plikiem.",
+       "api-feed-error-title": "Błąd ($1)",
+       "api-exception-trace": "$1 w $2($3)\n$4",
        "api-credits-header": "Twórcy",
        "api-credits": "Deweloperzy API:\n* Roan Kattouw (główny programista wrzesień 2007–2009)\n* Victor Vasiliev\n* Bryan Tong Minh\n* Sam Reed\n* Yuri Astrakhan (twórca, główny programista wrzesień 2006–wrzesień 2007)\n* Brad Jorsch (główny programista 2013–obecnie)\n\nProsimy wysyłać komentarze, sugestie i pytania do mediawiki-api@lists.wikimedia.org\nlub zgłoś błąd na https://phabricator.wikimedia.org/."
 }
index 20a2eda..e8980f5 100644 (file)
        "apihelp-query+allmessages-param-prop": "As propriedades a serem obtidas:",
        "apihelp-query+allmessages-param-enableparser": "Definir, para ativar o analisador sintático e pré-processar o texto da mensagem com notação wiki (substituir palavras mágicas, processar predefinições, etc.).",
        "apihelp-query+allmessages-param-nocontent": "Se definido, não incluir o conteúdo das mensagens no resultado de saída.",
-       "apihelp-query+allmessages-param-includelocal": "Incluir também as mensagens locais, isto é, mensagens que não existem no software mas existem como uma página no espaço nominal MediaWiki:.\nIsto lista todas as páginas do espaço nominal MediaWiki:, portanto, também irá listar aquelas que não são verdadeiramente mensagens, como [[MediaWiki:Common.js|Common.js]].",
+       "apihelp-query+allmessages-param-includelocal": "Incluir também as mensagens locais, isto é, mensagens que não existem no software mas existem como uma página no espaço nominal {{ns:MediaWiki}}.\nIsto lista todas as páginas do espaço nominal {{ns:MediaWiki}}, portanto, também irá listar aquelas que não são verdadeiramente mensagens, como [[MediaWiki:Common.js|Common.js]].",
        "apihelp-query+allmessages-param-args": "Os argumentos a serem substituídos na mensagem.",
        "apihelp-query+allmessages-param-filter": "Devolver só as mensagens cujos nomes contêm este texto.",
        "apihelp-query+allmessages-param-customised": "Devolver só as mensagens neste estado de personalização.",
        "apihelp-phpfm-description": "Produzir os dados de saída em formato PHP seriado (realce sintático em HTML).",
        "apihelp-rawfm-description": "Produzir os dados de saída, incluindo elementos para despiste de erros, em formato JSON (realce sintático em HTML).",
        "apihelp-xml-description": "Produzir os dados de saída em formato XML.",
-       "apihelp-xml-param-xslt": "Se especificado, adiciona a página nomeada como uma folha de estilo XSL. O valor tem de ser um título no espaço nominal {{ns:mediawiki}} e acabar em <code>.xsl</code>.",
+       "apihelp-xml-param-xslt": "Se especificado, adiciona a página nomeada como uma folha de estilo XSL. O valor tem de ser um título no espaço nominal {{ns:MediaWiki}} e acabar em <code>.xsl</code>.",
        "apihelp-xml-param-includexmlnamespace": "Se especificado, adiciona um espaço nominal XML.",
        "apihelp-xmlfm-description": "Produzir os dados de saída em formato XML (realce sintático em HTML).",
        "api-format-title": "Resultado da API do MediaWiki.",
index fd6a4dd..8cf338d 100644 (file)
        "apihelp-main-param-requestid": "{{doc-apihelp-param|main|requestid}}",
        "apihelp-main-param-servedby": "{{doc-apihelp-param|main|servedby}}",
        "apihelp-main-param-curtimestamp": "{{doc-apihelp-param|main|curtimestamp}}",
+       "apihelp-main-param-responselanginfo": "{{doc-apihelp-param|main|responselanginfo}}",
        "apihelp-main-param-origin": "{{doc-apihelp-param|main|origin}}",
        "apihelp-main-param-uselang": "{{doc-apihelp-param|main|uselang}}",
+       "apihelp-main-param-errorformat": "{{doc-apihelp-param|main|errorformat}}",
+       "apihelp-main-param-errorlang": "{{doc-apihelp-param|main|errorlang}}",
+       "apihelp-main-param-errorsuselocal": "{{doc-apihelp-param|main|errorsuselocal}}",
        "apihelp-block-description": "{{doc-apihelp-description|block}}",
        "apihelp-block-param-user": "{{doc-apihelp-param|block|user}}",
        "apihelp-block-param-expiry": "{{doc-apihelp-param|block|expiry}}\n{{doc-important|Do not translate \"5 months\", \"2 weeks\", \"infinite\", \"indefinite\" or \"never\"!}}",
        "api-help-authmanagerhelper-returnurl": "{{doc-apihelp-param|description=the \"returnurl\" parameter for AuthManager-using API modules|noseealso=1}}",
        "api-help-authmanagerhelper-continue": "{{doc-apihelp-param|description=the \"continue\" parameter for AuthManager-using API modules|noseealso=1}}",
        "api-help-authmanagerhelper-additional-params": "Message to display for AuthManager modules that take additional parameters to populate AuthenticationRequests. Parameters:\n* $1 - AuthManager action used by this module\n* $2 - Module parameter prefix, e.g. \"login\"\n* $3 - Module name, e.g. \"clientlogin\"\n* $4 - Module path, e.g. \"clientlogin\"",
+       "apierror-allimages-redirect": "{{doc-apierror}}",
+       "apierror-allpages-generator-redirects": "{{doc-apierror}}",
+       "apierror-appendnotsupported": "{{doc-apierror}}\n\nParameters:\n* $1 - Content model",
+       "apierror-articleexists": "{{doc-apierror}}",
+       "apierror-assertbotfailed": "{{doc-apierror}}",
+       "apierror-assertnameduserfailed": "{{doc-apierror}}\n\nParameters:\n* $1 - User name passed in.",
+       "apierror-assertuserfailed": "{{doc-apierror}}",
+       "apierror-autoblocked": "{{doc-apierror}}",
+       "apierror-badconfig-resulttoosmall": "{{doc-apierror}}",
+       "apierror-badcontinue": "{{doc-apierror}}",
+       "apierror-baddiff": "{{doc-apierror}}",
+       "apierror-baddiffto": "{{doc-apierror}}\n\nParameters:\n* $1 - Module parameter prefix, e.g. \"bl\".",
+       "apierror-badformat-generic": "{{doc-apierror}}\n\nParameters:\n* $1 - Content format.\n* $2 - Content model.",
+       "apierror-badformat": "{{doc-apierror}}\n\nParameters:\n* $1 - Content format.\n* $2 - Content model.\n* $3 - Title using the model.",
+       "apierror-badgenerator-notgenerator": "{{doc-apierror}}\n\nParameters:\n* $1 - Generator module name.",
+       "apierror-badgenerator-unknown": "{{doc-apierror}}\n\nParameters:\n* $1 - Generator module name.",
+       "apierror-badip": "{{doc-apierror}}",
+       "apierror-badmd5": "{{doc-apierror}}",
+       "apierror-badmodule-badsubmodule": "{{doc-apierror}}\n\nParameters:\n* $1 - Module path.\n* $2 - Submodule name.",
+       "apierror-badmodule-nosubmodules": "{{doc-apierror}}\n\nParameters:\n* $1 - Module path.",
+       "apierror-badparameter": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.",
+       "apierror-badquery": "{{doc-apierror}}",
+       "apierror-badtimestamp": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.\n* $2 - Value of the parameter.",
+       "apierror-badtoken": "{{doc-apierror}}",
+       "apierror-badupload": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.",
+       "apierror-badurl": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.\n* $2 - Value of the parameter.",
+       "apierror-baduser": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.\n* $2 - Value of the parameter.",
+       "apierror-badvalue-notmultivalue": "{{doc-apierror}}",
+       "apierror-bad-watchlist-token": "{{doc-apierror}}",
+       "apierror-blockedfrommail": "{{doc-apierror}}",
+       "apierror-blocked": "{{doc-apierror}}",
+       "apierror-botsnotsupported": "{{doc-apierror}}",
+       "apierror-cannotreauthenticate": "{{doc-apierror}}",
+       "apierror-cannotviewtitle": "{{doc-apierror}}\n\nParameters:\n* $1 - Title.",
+       "apierror-cantblock-email": "{{doc-apierror}}",
+       "apierror-cantblock": "{{doc-apierror}}",
+       "apierror-cantchangecontentmodel": "{{doc-apierror}}",
+       "apierror-canthide": "{{doc-apierror}}",
+       "apierror-cantimport-upload": "{{doc-apierror}}",
+       "apierror-cantimport": "{{doc-apierror}}",
+       "apierror-cantoverwrite-sharedfile": "{{doc-apierror}}",
+       "apierror-cantsend": "{{doc-apierror}}",
+       "apierror-cantundelete": "{{doc-apierror}}",
+       "apierror-changeauth-norequest": "{{doc-apierror}}",
+       "apierror-chunk-too-small": "{{doc-apierror}}\n\nParameters:\n* $1 - Minimum size in bytes.",
+       "apierror-cidrtoobroad": "{{doc-apierror}}\n\nParameters:\n* $1 - \"IPv4\" or \"IPv6\"\n* $2 - Minimum CIDR mask length.",
+       "apierror-compare-inputneeded": "{{doc-apierror}}",
+       "apierror-contentserializationexception": "{{doc-apierror}}\n\nParameters:\n* $1 - Exception text, may end with punctuation. Currently this is probably English, hopefully we'll fix that in the future.",
+       "apierror-contenttoobig": "{{doc-apierror}}\n\nParameters:\n* $1 - Maximum article size in kilobytes.",
+       "apierror-copyuploadbaddomain": "{{doc-apierror}}",
+       "apierror-copyuploadbadurl": "{{doc-apierror}}",
+       "apierror-create-titleexists": "{{doc-apierror}}",
+       "apierror-csp-report": "{{doc-apierror}}\n\nParameters:\n* $1 - Error code, e.g. \"toobig\".",
+       "apierror-databaseerror": "{{doc-apierror}}\n\nParameters:\n* $1 - Exception log ID code. This is meaningless to the end user, but can be used by people with access to the logs to easily find the logged error.",
+       "apierror-deletedrevs-param-not-1-2": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.\n\nSee also:\n* {{msg-mw|apihelp-query+deletedrevs-description}}",
+       "apierror-deletedrevs-param-not-3": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.\n\nSee also:\n* {{msg-mw|apihelp-query+deletedrevs-description}}",
+       "apierror-emptynewsection": "{{doc-apierror}}",
+       "apierror-emptypage": "{{doc-apierror}}",
+       "apierror-exceptioncaught": "{{doc-apierror}}\n\nParameters:\n* $1 - Exception log ID code. This is meaningless to the end user, but can be used by people with access to the logs to easily find the logged error.\n* $2 - Exception message, which may end with punctuation. Probably in English.",
+       "apierror-filedoesnotexist": "{{doc-apierror}}",
+       "apierror-fileexists-sharedrepo-perm": "{{doc-apierror}}",
+       "apierror-filenopath": "{{doc-apierror}}",
+       "apierror-filetypecannotberotated": "{{doc-apierror}}",
+       "apierror-formatphp": "{{doc-apierror}}",
+       "apierror-imageusage-badtitle": "{{doc-apierror}}\n\nParameters:\n* $1 - Module name.",
+       "apierror-import-unknownerror": "{{doc-apierror}}\n\nParameters:\n* $1 - Error message returned by the import, probably in English.",
+       "apierror-integeroutofrange-abovebotmax": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name\n* $2 - Maximum allowed value\n* $3 - Supplied value",
+       "apierror-integeroutofrange-abovemax": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name\n* $2 - Maximum allowed value\n* $3 - Supplied value",
+       "apierror-integeroutofrange-belowminimum": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name\n* $2 - Minimum allowed value\n* $3 - Supplied value",
+       "apierror-invalidcategory": "{{doc-apierror}}",
+       "apierror-invalid-chunk": "{{doc-apierror}}",
+       "apierror-invalidexpiry": "{{doc-apierror}}\n\nParameters:\n* $1 - Value provided.",
+       "apierror-invalid-file-key": "{{doc-apierror}}",
+       "apierror-invalidlang": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.",
+       "apierror-invalidoldimage": "{{doc-apierror}}",
+       "apierror-invalidparammix-cannotusewith": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name or \"parameter=value\" text.\n* $2 - Parameter name or \"parameter=value\" text.",
+       "apierror-invalidparammix-mustusewith": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name or \"parameter=value\" text.\n* $2 - Parameter name or \"parameter=value\" text.",
+       "apierror-invalidparammix-parse-new-section": "{{doc-apierror}}",
+       "apierror-invalidparammix": "{{doc-apierror}}\n\nParameters:\n* $1 - List of parameter names or \"parameter=value\" text.\n* $2 - Number of parameters.",
+       "apierror-invalidsection": "{{doc-apierror}}",
+       "apierror-invalidsha1base36hash": "{{doc-apierror}}",
+       "apierror-invalidsha1hash": "{{doc-apierror}}",
+       "apierror-invalidtitle": "{{doc-apierror}}\n\nParameters:\n* $1 - Title that is invalid",
+       "apierror-invalidurlparam": "{{doc-apierror}}\n\nParameters:\n* $1 - Module parameter prefix, e.g. \"bl\".\n* $2 - Key\n* $3 - Value.",
+       "apierror-invaliduser": "{{doc-apierror}}\n\nParameters:\n* $1 - User name that is invalid.",
+       "apierror-maxlag-generic": "{{doc-apierror}}\n\nParameters:\n* $1 - Database is lag in seconds.",
+       "apierror-maxlag": "{{doc-apierror}}\n\nParameters:\n* $1 - Database lag in seconds.\n* $2 - Database server that is lagged.",
+       "apierror-mimesearchdisabled": "{{doc-apierror}}",
+       "apierror-missingcontent-pageid": "{{doc-apierror}}\n\nParameters:\n* $1 - Page ID number.",
+       "apierror-missingparam-at-least-one-of": "{{doc-apierror}}\n\nParameters:\n* $1 - List of parameter names.\n* $2 - Number of parameters.",
+       "apierror-missingparam-one-of": "{{doc-apierror}}\n\nParameters:\n* $1 - List of parameter names.\n* $2 - Number of parameters.",
+       "apierror-missingparam": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.",
+       "apierror-missingrev-pageid": "{{doc-apierror}}\n\nParameters:\n* $1 - Page ID number.",
+       "apierror-missingtitle-createonly": "{{doc-apierror}}",
+       "apierror-missingtitle": "{{doc-apierror}}",
+       "apierror-missingtitle-byname": "{{doc-apierror}}",
+       "apierror-moduledisabled": "{{doc-apierror}}\n\nParameters:\n* $1 - Name of the module.",
+       "apierror-multival-only-one-of": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.\n* $2 - Possible values for the parameter.\n* $3 - Number of values.",
+       "apierror-multival-only-one": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.",
+       "apierror-multpages": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name",
+       "apierror-mustbeloggedin-changeauth": "{{doc-apierror}}",
+       "apierror-mustbeloggedin-generic": "{{doc-apierror}}",
+       "apierror-mustbeloggedin-linkaccounts": "{{doc-apierror}}",
+       "apierror-mustbeloggedin-removeauth": "{{doc-apierror}}",
+       "apierror-mustbeloggedin-uploadstash": "{{doc-apierror}}",
+       "apierror-mustbeloggedin": "{{doc-apierror}}\n\nParameters:\n* $1 - One of the action-* messages (for example {{msg-mw|action-edit}}) or other such messages tagged with {{tl|doc-action}} in their documentation\n\nPlease report at [[Support]] if you are unable to properly translate this message. Also see [[phab:T16246]] (now closed) for background.\n\nSee also:\n* {{msg-mw|apierror-permissiondenied}}\n* {{msg-mw|permissionserrorstext-withaction}}",
+       "apierror-mustbeposted": "{{doc-apierror}}\n\nParameters:\n* $1 - Module name.",
+       "apierror-mustpostparams": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter names.\n* $2 - Number of parameters.",
+       "apierror-noapiwrite": "{{doc-apierror}}",
+       "apierror-nochanges": "{{doc-apierror}}",
+       "apierror-nodeleteablefile": "{{doc-apierror}}",
+       "apierror-no-direct-editing": "{{doc-apierror}}\n\nParameters:\n* $1 - Content model.\n* $2 - Title using the model.",
+       "apierror-noedit-anon": "{{doc-apierror}}",
+       "apierror-noedit": "{{doc-apierror}}",
+       "apierror-noimageredirect-anon": "{{doc-apierror}}",
+       "apierror-noimageredirect": "{{doc-apierror}}",
+       "apierror-nosuchlogid": "{{doc-apierror}}\n\nParameters:\n* $1 - Log ID number.",
+       "apierror-nosuchpageid": "{{doc-apierror}}\n\nParameters:\n* $1 - Page ID number.",
+       "apierror-nosuchrcid": "{{doc-apierror}}\n\nParameters:\n* $1 - RecentChanges ID number.",
+       "apierror-nosuchrevid": "{{doc-apierror}}\n\nParameters:\n* $1 - Revision ID number.",
+       "apierror-nosuchsection": "{{doc-apierror}}\n\nParameters:\n* $1 - Section identifier. Probably a number or \"T-\" followed by a number.",
+       "apierror-nosuchsection-what": "{{doc-apierror}}\n\nParameters:\n* $1 - Section identifier. Probably a number or \"T-\" followed by a number.\n* $2 - Page title, revision ID formatted with {{msg-mw|revid}}, or page ID formatted with {{msg-mw|pageid}}.",
+       "apierror-notarget": "{{doc-apierror}}",
+       "apierror-notpatrollable": "{{doc-apierror}}\n\nParameters:\n* $1 - Revision ID number.",
+       "apierror-nouploadmodule": "{{doc-apierror}}",
+       "apierror-opensearch-json-warnings": "{{doc-apierror}}",
+       "apierror-pagecannotexist": "{{doc-apierror}}",
+       "apierror-pagedeleted": "{{doc-apierror}}",
+       "apierror-paramempty": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.",
+       "apierror-parsetree-notwikitext": "{{doc-apierror}}",
+       "apierror-parsetree-notwikitext-title": "{{doc-apierror}}\n\nParameters:\n* $1 - Page title.\n* $2 - Content model.",
+       "apierror-pastexpiry": "{{doc-apierror}}\n\nParameters:\n* $1 - Supplied expiry time.",
+       "apierror-permissiondenied": "{{doc-apierror}}\n\nParameters:\n* $1 - One of the action-* messages (for example {{msg-mw|action-edit}}) or other such messages tagged with {{tl|doc-action}} in their documentation\n\nPlease report at [[Support]] if you are unable to properly translate this message. Also see [[phab:T16246]] (now closed) for background.\n\nSee also:\n* {{msg-mw|permissionserrorstext-withaction}}",
+       "apierror-permissiondenied-generic": "{{doc-apierror}}",
+       "apierror-permissiondenied-patrolflag": "{{doc-apierror}}\n\nSee also:\n* {{msg-mw|apierror-permissiondenied}}",
+       "apierror-permissiondenied-unblock": "{{doc-apierror}}\n\nSee also:\n* {{msg-mw|apierror-permissiondenied}}",
+       "apierror-prefixsearchdisabled": "{{doc-apierror}}",
+       "apierror-promised-nonwrite-api": "{{doc-apierror}}",
+       "apierror-protect-invalidaction": "{{doc-apierror}}\n\nParameters:\n* $1 - Supplied protection type.",
+       "apierror-protect-invalidlevel": "{{doc-apierror}}\n\nParameters:\n* $1 - Supplied protection level.",
+       "apierror-ratelimited": "{{doc-apierror}}",
+       "apierror-readapidenied": "{{doc-apierror}}",
+       "apierror-readonly": "{{doc-apierror}}",
+       "apierror-reauthenticate": "{{doc-apierror}}",
+       "apierror-redirect-appendonly": "{{doc-apierror}}",
+       "apierror-revdel-mutuallyexclusive": "{{doc-apierror}}",
+       "apierror-revdel-needtarget": "{{doc-apierror}}",
+       "apierror-revdel-paramneeded": "{{doc-apierror}}",
+       "apierror-revisions-norevids": "{{doc-apierror}}\n\nParameters:\n* $1 - Module parameter prefix, e.g. \"bl\".",
+       "apierror-revisions-singlepage": "{{doc-apierror}}\n\nParameters:\n* $1 - Module parameter prefix, e.g. \"bl\".",
+       "apierror-revwrongpage": "{{doc-apierror}}\n\nParameters:\n* $1 - Revision ID number.\n* $2 - Page title.",
+       "apierror-searchdisabled": "{{doc-apierror}}\n\nParameters:\n* $1 - Search parameter that is disabled.",
+       "apierror-sectionreplacefailed": "{{doc-apierror}}",
+       "apierror-sectionsnotsupported": "{{doc-apierror}}\n\nParameters:\n* $1 - Content model that doesn't support sections.",
+       "apierror-sectionsnotsupported-what": "{{doc-apierror}}\n\nParameters:\n* $1 - Page title, revision ID formatted with {{msg-mw|revid}}, or page ID formatted with {{msg-mw|pageid}}.",
+       "apierror-show": "{{doc-apierror}}",
+       "apierror-siteinfo-includealldenied": "{{doc-apierror}}",
+       "apierror-sizediffdisabled": "{{doc-apierror}}",
+       "apierror-spamdetected": "{{doc-apierror}}\n\nParameters:\n* $1 - Matching \"spam filter\".\n\nSee also:\n* {{msg-mw|spamprotectionmatch}}",
+       "apierror-specialpage-cantexecute": "{{doc-apierror}}",
+       "apierror-stashedfilenotfound": "{{doc-apierror}}\n\nParameters:\n* $1 - Exception text. Currently this is probably English, hopefully we'll fix that in the future.",
+       "apierror-stashedit-missingtext": "{{doc-apierror}}",
+       "apierror-stashfailed-complete": "{{doc-apierror}}",
+       "apierror-stashfailed-nosession": "{{doc-apierror}}",
+       "apierror-stashfilestorage": "{{doc-apierror}}\n\nParameters:\n* $1 - Exception text, which may already end with punctuation. Currently this is probably English, hopefully we'll fix that in the future.",
+       "apierror-stashnosuchfilekey": "{{doc-apierror}}\n\nParameters:\n* $1 - Exception text. Currently this is probably English, hopefully we'll fix that in the future.",
+       "apierror-stashpathinvalid": "{{doc-apierror}}\n\nParameters:\n* $1 - Exception text. Currently this is probably English, hopefully we'll fix that in the future.",
+       "apierror-stashwrongowner": "{{doc-apierror}}\n\nParameters:\n* $1 - Exception text, which should already end with punctuation. Currently this is probably English, hopefully we'll fix that in the future.",
+       "apierror-stashzerolength": "{{doc-apierror}}\n\nParameters:\n* $1 - Exception text. Currently this is probably English, hopefully we'll fix that in the future.",
+       "apierror-templateexpansion-notwikitext": "{{doc-apierror}}\n\nParameters:\n* $1 - Page title.\n* $2 - Content model.",
+       "apierror-toofewexpiries": "{{doc-apierror}}\n\nParameters:\n* $1 - Number provided.\n* $2 - Number needed.",
+       "apierror-unknownaction": "{{doc-apierror}}\n\nParameters:\n* $1 - Action provided.",
+       "apierror-unknownerror-editpage": "{{doc-apierror}}\n\nParameters:\n* $1 - Error code (an integer).",
+       "apierror-unknownerror-nocode": "{{doc-apierror}}",
+       "apierror-unknownerror": "{{doc-apierror}}\n\nParameters:\n* $1 - Error code (possibly a message key) not handled by ApiBase::parseMsg().",
+       "apierror-unknownformat": "{{doc-apierror}}\n\nParameters:\n* $1 - Format provided.",
+       "apierror-unrecognizedparams": "{{doc-apierror}}\n\nParameters:\n* $1 - List of parameters.\n* $2 - Number of parameters.",
+       "apierror-unrecognizedvalue": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.\n* $2 - Parameter value.",
+       "apierror-unsupportedrepo": "{{doc-apierror}}",
+       "apierror-upload-filekeyneeded": "{{doc-apierror}}",
+       "apierror-upload-filekeynotallowed": "{{doc-apierror}}",
+       "apierror-upload-inprogress": "{{doc-apierror}}",
+       "apierror-upload-missingresult": "{{doc-apierror}}",
+       "apierror-urlparamnormal": "{{doc-apierror}}\n\nParameters:\n* $1 - Image title.",
+       "apierror-writeapidenied": "{{doc-apierror}}",
+       "apiwarn-alldeletedrevisions-performance": "{{doc-apierror}}\n\nParameters:\n* $1 - Module parameter prefix, e.g. \"bl\".",
+       "apiwarn-badurlparam": "{{doc-apierror}}\n\nParameters:\n* $1 - Module parameter prefix, e.g. \"bl\".\n* $2 - Image title.",
+       "apiwarn-badutf8": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.",
+       "apiwarn-checktoken-percentencoding": "{{doc-apierror}}",
+       "apiwarn-deprecation-deletedrevs": "{{doc-apierror}}",
+       "apiwarn-deprecation-expandtemplates-prop": "{{doc-apierror}}",
+       "apiwarn-deprecation-httpsexpected": "{{doc-apierror}}",
+       "apiwarn-deprecation-login-botpw": "{{doc-apierror}}",
+       "apiwarn-deprecation-login-nobotpw": "{{doc-apierror}}",
+       "apiwarn-deprecation-login-token": "{{doc-apierror}}",
+       "apiwarn-deprecation-parameter": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.",
+       "apiwarn-deprecation-parse-headitems": "{{doc-apierror}}",
+       "apiwarn-deprecation-purge-get": "{{doc-apierror}}",
+       "apiwarn-deprecation-withreplacement": "{{doc-apierror}}\n\nParameters:\n* $1 - Query string fragment that is deprecated, e.g. \"action=tokens\".\n* $2 - Query string fragment to use instead, e.g. \"action=tokens\".",
+       "apiwarn-difftohidden": "{{doc-apierror}}\n\nParameters:\n* $1 - Revision ID number.",
+       "apiwarn-errorprinterfailed": "{{doc-apierror}}",
+       "apiwarn-errorprinterfailed-ex": "{{doc-apierror}}\n\nParameters:\n* $1 - Exception message, which may already end in punctuation. Probably in English.",
+       "apiwarn-invalidcategory": "{{doc-apierror}}\n\nParameters:\n* $1 - Supplied category name.",
+       "apiwarn-invalidtitle": "{{doc-apierror}}\n\nParameters:\n* $1 - Supplied title.",
+       "apiwarn-invalidxmlstylesheetext": "{{doc-apierror}}",
+       "apiwarn-invalidxmlstylesheet": "{{doc-apierror}}",
+       "apiwarn-invalidxmlstylesheetns": "{{doc-apierror}}",
+       "apiwarn-moduleswithoutvars": "{{doc-apierror}}",
+       "apiwarn-notfile": "{{doc-apierror}}\n\nParameters:\n* $1 - Supplied file name.",
+       "apiwarn-nothumb-noimagehandler": "{{doc-apierror}}\n\nParameters:\n* $1 - File name.",
+       "apiwarn-parse-nocontentmodel": "{{doc-apierror}}\n\nParameters:\n* $1 - Content model being assumed.",
+       "apiwarn-parse-titlewithouttext": "{{doc-apierror}}",
+       "apiwarn-redirectsandrevids": "{{doc-apierror}}",
+       "apiwarn-tokennotallowed": "{{doc-apierror}}\n\nParameters:\n* $1 - Token type being requested, typically named after the action requiring the token.",
+       "apiwarn-tokens-origin": "{{doc-apierror}}",
+       "apiwarn-toomanyvalues": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.\n* $2 - Maximum number of values allowed.",
+       "apiwarn-truncatedresult": "{{doc-apierror}}\n\nParameters:\n* $1 - Size limit in bytes.",
+       "apiwarn-unclearnowtimestamp": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.\n* $2 - Supplied value.",
+       "apiwarn-unrecognizedvalues": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.\n* $2 - List of unknown values supplied.\n* $3 - Number of unknown values.",
+       "apiwarn-unsupportedarray": "{{doc-apierror}}\n\nParameters:\n* $1 - Parameter name.",
+       "apiwarn-urlparamwidth": "{{doc-apierror}}\n\nParameters:\n* $1 - Module parameter prefix, e.g. \"bl\".\n* $2 - Width being ignored.\n* $3 - Width being used.",
+       "apiwarn-validationfailed-badchars": "{{doc-apierror}}\n\nUsed with {{msg-mw|apiwarn-validationfailed}}.",
+       "apiwarn-validationfailed-badpref": "{{doc-apierror}}\n\nUsed with {{msg-mw|apiwarn-validationfailed}}.",
+       "apiwarn-validationfailed-cannotset": "{{doc-apierror}}\n\nUsed with {{msg-mw|apiwarn-validationfailed}}.",
+       "apiwarn-validationfailed-keytoolong": "{{doc-apierror}}\n\nUsed with {{msg-mw|apiwarn-validationfailed}}.\n\nParameters:\n* $1 - Maximum allowed key length in bytes.",
+       "apiwarn-validationfailed": "{{doc-apierror}}\n\nParameters:\n* $1 - User preference name.\n* $2 - Failure message, such as {{msg-mw|apiwarn-validationfailed-badpref}}. Probably already ends with punctuation",
+       "apiwarn-wgDebugAPI": "{{doc-apierror}}",
+       "api-feed-error-title": "Used as a feed item title when an error occurs in <kbd>action=feedwatchlist</kbd>.\n\nParameters:\n* $1 - API error code",
+       "api-usage-docref": "\n\nParameters:\n* $1 - URL of the API auto-generated documentation.",
+       "api-exception-trace": "\n\nParameters:\n* $1 - Exception class.\n* $2 - File from which the exception was thrown.\n* $3 - Line number from which the exception was thrown.\n* $4 - Exception backtrace.",
        "api-credits-header": "Header for the API credits section in the API help output\n{{Identical|Credit}}",
        "api-credits": "API credits text, displayed in the API help output"
 }
index d5b4c62..4e42a10 100644 (file)
        "apihelp-phpfm-description": "Виводити дані у форматі серіалізованого PHP (вивід відформатованого коду за допомогою HTML).",
        "apihelp-rawfm-description": "Виводити дані, включно з елементами налагодження, у форматі JSON (вивід відформатованого коду за допомогою HTML).",
        "apihelp-xml-description": "Виводити дані у форматі XML.",
-       "apihelp-xml-param-xslt": "Якщо вказано, додає названу сторінку як таблицю стилів XSL. Це значення повинне бути назвою у просторі назв {{ns:mediawiki}}, що закінчується на <code>.xsl</code>.",
+       "apihelp-xml-param-xslt": "Якщо вказано, додає названу сторінку як таблицю стилів XSL. Це значення повинне бути назвою у просторі назв {{ns:MediaWiki}}, що закінчується на <code>.xsl</code>.",
        "apihelp-xml-param-includexmlnamespace": "Якщо вказано, додає простір назв XML.",
        "apihelp-xmlfm-description": "Вивести дані у форматі XML (вивід відформатованого коду за допомогою HTML).",
        "api-format-title": "Результат запиту до API MediaWiki",
index 60295aa..b96d3a1 100644 (file)
        "apihelp-phpfm-description": "输出数据为序列化PHP格式(HTML优质打印效果)。",
        "apihelp-rawfm-description": "输出数据为JSON格式,包含调试元素(HTML优质打印效果)。",
        "apihelp-xml-description": "输出数据为XML格式。",
-       "apihelp-xml-param-xslt": "如果指定,加入已命名的页面作为一个XSL样式表。值必须是在{{ns:mediawiki}}名字空间以<code>.xsl</code>为结尾的标题。",
+       "apihelp-xml-param-xslt": "如果指定,加入已命名的页面作为一个XSL样式表。值必须是在{{ns:MediaWiki}}名字空间以<code>.xsl</code>为结尾的标题。",
        "apihelp-xml-param-includexmlnamespace": "如果指定,添加一个XML名字空间。",
        "apihelp-xmlfm-description": "输出数据为XML格式(HTML优质打印效果)。",
        "api-format-title": "MediaWiki API 结果",
index e24541c..f58acbe 100644 (file)
@@ -6,7 +6,8 @@ class HTMLTagFilter extends HTMLFormField {
        protected $tagFilter;
 
        public function getTableRow( $value ) {
-               $this->tagFilter = ChangeTags::buildTagFilterSelector( $value );
+               $this->tagFilter = ChangeTags::buildTagFilterSelector(
+                       $value, false, $this->mParent->getContext() );
                if ( $this->tagFilter ) {
                        return parent::getTableRow( $value );
                }
@@ -14,7 +15,8 @@ class HTMLTagFilter extends HTMLFormField {
        }
 
        public function getDiv( $value ) {
-               $this->tagFilter = ChangeTags::buildTagFilterSelector( $value );
+               $this->tagFilter = ChangeTags::buildTagFilterSelector(
+                       $value, false, $this->mParent->getContext() );
                if ( $this->tagFilter ) {
                        return parent::getDiv( $value );
                }
index f28e2c5..f9a8da8 100644 (file)
        "config-help": "সাহায্য",
        "config-help-tooltip": "প্রসারিত করতে ক্লিক করুন",
        "mainpagetext": "<strong>মিডিয়াউইকি ইনস্টল করা হয়েছে।</strong>",
-       "mainpagedocfooter": "কীভাবে উইকি সফটওয়্যারটি ব্যবহারকার করবেন, তা জানতে [https://www.mediawiki.org/wiki/Special:MyLanguage/Help:Contents ব্যবহারকারী সহায়িকা] দেখুন।\n\n== কোথা থেকে শুরু করবেন ==\n\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Configuration_settings কনফিগারেশন সেটিং তালিকা]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:FAQ প্রশ্নোত্তরে মিডিয়াউইকি]\n* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce মিডিয়াউইকি মুক্তির মেইলিং লিস্ট]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Localisation#Translation_resources আপনার ভাষার জন্য মিডিয়াউইকি স্থানীয়করণ করুন]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Combating_spam আপনার উইকিতে স্প্যামের সাথে লড়াই করার উপায় সম্পর্কে জানুন]"
+       "mainpagedocfooter": "কীভাবে উইকি সফটওয়্যারটি ব্যবহারকার করবেন, তা জানতে [https://www.mediawiki.org/wiki/Special:MyLanguage/Help:Contents ব্যবহারকারী সহায়িকা] দেখুন।\n\n== কোথা থেকে শুরু করবেন ==\n\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Configuration_settings কনফিগারেশন সেটিং তালিকা]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:FAQ প্রশ্নোত্তরে মিডিয়াউইকি]\n* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce মিডিয়াউইকি মুক্তির মেইলিং লিস্ট]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Localisation#Translation_resources আপনার ভাষার জন্য মিডিয়াউইকি স্থানীয়করণ করুন]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Combating_spam আপনার উইকিতে স্প্যামের সাথে লড়াই করার উপায় সম্পর্কে জানুন]"
 }
index 82a2373..6257691 100644 (file)
        "config-nofile": "Le fichier « $1 » est introuvable. A-t-il été supprimé ?",
        "config-extension-link": "Saviez-vous que votre wiki prend en charge [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Extensions des extensions] ?\n\nVous pouvez consulter les [https://www.mediawiki.org/wiki/Special:MyLanguage/Category:Extensions_by_category extensions par catégorie] ou la [https://www.mediawiki.org/wiki/Extension_Matrix matrice des extensions] pour voir la liste complète des extensions.",
        "mainpagetext": "<strong>MediaWiki a été installé.</strong>",
-       "mainpagedocfooter": "Consultez le [https://meta.wikimedia.org/wiki/Help:Contents/fr Guide de l’utilisateur] pour plus d’informations sur l’utilisation de ce logiciel de wiki.\n\n== Pour démarrer ==\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Configuration_settings Liste des paramètres de configuration]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:FAQ/fr Questions courantes sur MediaWiki]\n* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce Liste de discussion sur les distributions de MediaWiki]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Localisation#Translation_resources Adaptez MediaWiki dans votre langue]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Combating_spam Apprendre comment lutter contre le pourriel dans votre wiki]"
+       "mainpagedocfooter": "Consultez le [https://meta.wikimedia.org/wiki/Help:Contents/fr Guide de l’utilisateur du contenu] pour plus d’informations sur l’utilisation de ce logiciel de wiki.\n\n== Pour démarrer ==\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Configuration_settings Liste des paramètres de configuration]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:FAQ/fr Questions courantes sur MediaWiki]\n* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce Liste de discussion sur les distributions de MediaWiki]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Localisation#Translation_resources Adaptez MediaWiki dans votre langue]\n* [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Combating_spam Apprendre comment lutter contre le pourriel dans votre wiki]"
 }
index ce3ae88..dd25b48 100644 (file)
        "config-install-schema": "스키마를 만드는 중",
        "config-install-pg-schema-not-exist": "PostgreSQL 스키마가 존재하지 않습니다.",
        "config-install-pg-schema-failed": "테이블을 만드는 데 실패했습니다.\n\"$2\" 스키마에 쓸 수 있는 \"$1\" 사용자가 있는지 확인하세요.",
-       "config-install-pg-commit": "ë°\94ë\80\90 사항을 적용하는 중",
+       "config-install-pg-commit": "ë³\80ê²½사항을 적용하는 중",
        "config-install-pg-plpgsql": "PL/pgSQL 언어에 대해 확인하는 중",
        "config-pg-no-plpgsql": "$1 데이터베이스에 PL/pgSQL 언어를 설치해야 합니다",
        "config-pg-no-create-privs": "설치를 위한 지정한 계정에 계정을 만드는 데 충분한 권한이 없습니다,",
index d7e86be..7b60ed0 100644 (file)
@@ -17,7 +17,8 @@
                        "Siebrand",
                        "Umherirrender",
                        "Waldir",
-                       "Jdforrester"
+                       "Jdforrester",
+                       "Liuxinyu970226"
                ]
        },
        "config-desc": "Short description of the installer.",
        "config-help": "This is used in help boxes.\n{{Identical|Help}}",
        "config-help-tooltip": "Tooltip for the 'help' links ({{msg-mw|config-help}}), to make it clear they'll expand in place rather than open a new page",
        "config-nofile": "Used as failure message. Parameters:\n* $1 - filename",
-       "config-extension-link": "Shown on last page of installation to inform about possible extensions.",
+       "config-extension-link": "Shown on last page of installation to inform about possible extensions.\n{{Identical|Did you know}}",
        "mainpagetext": "Along with {{msg-mw|mainpagedocfooter}}, the text you will see on the Main Page when your wiki is installed.",
        "mainpagedocfooter": "Along with {{msg-mw|mainpagetext}}, the text you will see on the Main Page when your wiki is installed.\nThis might be a good place to put information about <nowiki>{{GRAMMAR:}}</nowiki>. See [[{{NAMESPACE}}:{{BASEPAGENAME}}/fi]] for an example. For languages having grammatical distinctions and not having an appropriate <nowiki>{{GRAMMAR:}}</nowiki> software available, a suggestion to check and possibly amend the messages having <nowiki>{{SITENAME}}</nowiki> may be valuable. See [[{{NAMESPACE}}:{{BASEPAGENAME}}/ksh]] for an example."
 }
index 25d8c7c..d2d5d3c 100644 (file)
        "config-profile-help": "如果您允许尽量多的人编写wiki,网站上的内容会更加丰富。在MediaWiki中,您可以轻松地审查最近更改,并轻易回退掉新手或破坏者造成的损害。\n\n然而,许多人觉得让MediaWiki存在多种角色将更加好用;同时,要说服所有人都愿以wiki的方式作贡献并非一件易事。因此,您可以有以下选择:\n\n<strong>{{int:config-profile-wiki}}</strong>模式允许包括未登录用户在内的所有人编辑。<strong>{{int:config-profile-no-anon}}</strong>的wiki需要额外的注册流程,这有可能会阻碍随意贡献者。\n\n<strong>{{int:config-profile-fishbowl}}</strong>方案只允许获批准的用户编辑,但对公众开放页面浏览(包括历史记录)。<strong>{{int:config-profile-private}}</strong>则只允许获批准的用户浏览、编辑页面。\n\n安装完成后,您还可以对用户权限进行更多、更复杂的配置,参见[https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:User_rights 相关的使用手册]。",
        "config-license": "版权和许可证:",
        "config-license-none": "页脚无许可证",
-       "config-license-cc-by-sa": "知识共享“署名-相同方式共享”",
+       "config-license-cc-by-sa": "知识共享署名-相同方式共享",
        "config-license-cc-by": "知识共享署名",
        "config-license-cc-by-nc-sa": "知识共享署名-非商业性使用-相同方式共享",
        "config-license-cc-0": "知识共享Zero(公有领域)",
index 2f2e934..b977af5 100644 (file)
        "config-profile-help": "Wiki 最佳的運作方式是盡可能讓大家都可以編輯文件。\n在 MediaWiki,可以很輕易的審查最近做的所有變更動作,並且可以還原由新手或惡意使用者造成的損害。\n\n不論如何,很多人發現 MediaWiki 可以廣泛的運用在各種地方,但並不是很容易可以說服每個人都遵守對 Wiki 有益的方式。\n所以您必須做出以下選擇。\n\n使用 <strong>{{int:config-profile-wiki}}</strong> 模式,允許所有人編輯文章,包含未匿名使用者。\n使用 <strong>{{int:config-profile-no-anon}}</strong> 模式,允許所有人編輯文章,不包含未登入的使用者。此模式較能管理所有使用者的言論,但會扼殺臨時使用者的貢獻機會。\n\n使用 <strong>{{int:config-profile-fishbowl}}</strong> 模式,僅經核准的使用者可以編輯,所有人可以檢視頁面,包含修訂的記錄。\n使用 <strong>{{int:config-profile-private}}</strong> 模式,僅經核准的使用者可以編輯、檢視頁面。\n\n有關更多複雜的使用者權限設定可在安裝程序結束後設定,請參考 [https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:User_rights 相關文件說明]。",
        "config-license": "版權聲明與授權條款:",
        "config-license-none": "無授權條款頁腳",
-       "config-license-cc-by-sa": "創作共用 姓名標示-相同方式分享",
-       "config-license-cc-by": "創作共用 Attribution",
+       "config-license-cc-by-sa": "創用 CC 姓名標示-相同方式分享",
+       "config-license-cc-by": "創用 CC 姓名標示",
        "config-license-cc-by-nc-sa": "創作共用 Attribution-NonCommercial-ShareAlike",
        "config-license-cc-0": "創作共用 Zero (公有領域)",
        "config-license-gfdl": "GNU 自由文件授權條款 1.3 或更高版本",
index 2f5a454..db6869b 100644 (file)
@@ -58,7 +58,7 @@ class MapCacheLRU {
         * @return void
         */
        public function set( $key, $value ) {
-               if ( array_key_exists( $key, $this->cache ) ) {
+               if ( $this->has( $key ) ) {
                        $this->ping( $key );
                } elseif ( count( $this->cache ) >= $this->maxCacheKeys ) {
                        reset( $this->cache );
@@ -75,6 +75,9 @@ class MapCacheLRU {
         * @return bool
         */
        public function has( $key ) {
+               if ( !is_int( $key ) && !is_string( $key ) ) {
+                       throw new MWException( __METHOD__ . ' called with invalid key. Must be string or integer.' );
+               }
                return array_key_exists( $key, $this->cache );
        }
 
@@ -87,7 +90,7 @@ class MapCacheLRU {
         * @return mixed Returns null if the key was not found
         */
        public function get( $key ) {
-               if ( !array_key_exists( $key, $this->cache ) ) {
+               if ( !$this->has( $key ) ) {
                        return null;
                }
 
index 9c1ec8e..016c9b1 100644 (file)
  * <https://github.com/phacility/xhprof>. XHProf can be installed as a PECL
  * package for use with PHP5 (Zend PHP) and is built-in to HHVM 3.3.0.
  *
+ * This also supports using the Tideways profiler
+ * <https://github.com/tideways/php-profiler-extension>, which additionally
+ * has support for PHP7.
+ *
  * @since 1.28
  */
 class Xhprof {
@@ -43,10 +47,16 @@ class Xhprof {
         */
        public static function enable( $flags = 0, $options = [] ) {
                if ( self::isEnabled() ) {
-                       throw new Exception( 'Xhprof profiling is already enabled.' );
+                       throw new Exception( 'Profiling is already enabled.' );
                }
                self::$enabled = true;
-               xhprof_enable( $flags, $options );
+               if ( function_exists( 'xhprof_enable' ) ) {
+                       xhprof_enable( $flags, $options );
+               } elseif ( function_exists( 'tideways_enable' ) ) {
+                       tideways_enable( $flags, $options );
+               } else {
+                       throw new Exception( "Neither xhprof nor tideways are installed" );
+               }
        }
 
        /**
@@ -57,7 +67,12 @@ class Xhprof {
        public static function disable() {
                if ( self::isEnabled() ) {
                        self::$enabled = false;
-                       return xhprof_disable();
+                       if ( function_exists( 'xhprof_disable' ) ) {
+                               return xhprof_disable();
+                       } else {
+                               // tideways
+                               return tideways_disable();
+                       }
                }
        }
 }
index 02b3c92..6e6a3ad 100644 (file)
@@ -72,7 +72,7 @@ class APCUBagOStuff extends APCBagOStuff {
                if ( apcu_exists( $key . self::KEY_SUFFIX ) ) {
                        return apcu_inc( $key . self::KEY_SUFFIX, $value );
                } else {
-                       return apcu_set( $key . self::KEY_SUFFIX, $value );
+                       return false;
                }
        }
 
@@ -85,7 +85,7 @@ class APCUBagOStuff extends APCBagOStuff {
                if ( apcu_exists( $key . self::KEY_SUFFIX ) ) {
                        return apcu_dec( $key . self::KEY_SUFFIX, $value );
                } else {
-                       return apcu_set( $key . self::KEY_SUFFIX, -$value );
+                       return false;
                }
        }
 }
index 7317d54..a06aad2 100644 (file)
@@ -41,7 +41,7 @@ class DatabaseSqlite extends Database {
        /** @var resource */
        protected $mLastResult;
 
-       /** @var $mConn PDO */
+       /** @var PDO */
        protected $mConn;
 
        /** @var FSLockManager (hopefully on the same server as the DB) */
index d42fed9..634993a 100644 (file)
@@ -31,7 +31,7 @@ use Wikimedia\ScopedCallback;
 class LoadBalancer implements ILoadBalancer {
        /** @var array[] Map of (server index => server config array) */
        private $mServers;
-       /** @var array[] Map of (local/foreignUsed/foreignFree => server index => IDatabase array) */
+       /** @var IDatabase[][] Map of (local/foreignUsed/foreignFree => server index => IDatabase array) */
        private $mConns;
        /** @var float[] Map of (server index => weight) */
        private $mLoads;
@@ -390,6 +390,9 @@ class LoadBalancer implements ILoadBalancer {
                return $i;
        }
 
+       /**
+        * @param DBMasterPos|false $pos
+        */
        public function waitFor( $pos ) {
                $this->mWaitForPos = $pos;
                $i = $this->mReadIndex;
@@ -436,6 +439,10 @@ class LoadBalancer implements ILoadBalancer {
                return $ok;
        }
 
+       /**
+        * @param int $i
+        * @return IDatabase
+        */
        public function getAnyOpenConnection( $i ) {
                foreach ( $this->mConns as $connsByServer ) {
                        if ( !empty( $connsByServer[$i] ) ) {
@@ -1447,6 +1454,11 @@ class LoadBalancer implements ILoadBalancer {
                }
        }
 
+       /**
+        * @param IDatabase $conn
+        * @param DBMasterPos|false $pos
+        * @param int $timeout
+        */
        public function safeWaitForMasterPos( IDatabase $conn, $pos = false, $timeout = 10 ) {
                if ( $this->getServerCount() <= 1 || !$conn->getLBInfo( 'replica' ) ) {
                        return true; // server is not a replica DB
index 57a7597..6665336 100644 (file)
@@ -93,7 +93,7 @@ class LogEventsList extends ContextSource {
                // For B/C, we take strings, but make sure they are converted...
                $types = ( $types === '' ) ? [] : (array)$types;
 
-               $tagSelector = ChangeTags::buildTagFilterSelector( $tagFilter );
+               $tagSelector = ChangeTags::buildTagFilterSelector( $tagFilter, false, $this->getContext() );
 
                $html = Html::hidden( 'title', $title->getPrefixedDBkey() );
 
index 47dae78..de49fc3 100644 (file)
@@ -22,6 +22,7 @@
  */
 
 use \MediaWiki\MediaWikiServices;
+use \Wikimedia\WaitConditionLoop;
 
 /**
  * Class to store objects in the database
index 74566cb..1fa4bfa 100644 (file)
@@ -224,4 +224,20 @@ class WikiFilePage extends WikiPage {
 
                return TitleArray::newFromResult( $res );
        }
+
+       /**
+        * @since 1.28
+        * @return string
+        */
+       public function getWikiDisplayName() {
+               return $this->getFile()->getRepo()->getDisplayName();
+       }
+
+       /**
+        * @since 1.28
+        * @return string
+        */
+       public function getSourceURL() {
+               return $this->getFile()->getDescriptionUrl();
+       }
 }
index 284a343..924a395 100644 (file)
@@ -3727,4 +3727,30 @@ class WikiPage implements Page, IDBAccessObject {
        public function isLocal() {
                return true;
        }
+
+       /**
+        * The display name for the site this content
+        * come from. If a subclass overrides isLocal(),
+        * this could return something other than the
+        * current site name
+        *
+        * @since 1.28
+        * @return string
+        */
+       public function getWikiDisplayName() {
+               global $wgSitename;
+               return $wgSitename;
+       }
+
+       /**
+        * Get the source URL for the content on this page,
+        * typically the canonical URL, but may be a remote
+        * link if the content comes from another site
+        *
+        * @since 1.28
+        * @return string
+        */
+       public function getSourceURL() {
+               return $this->getTitle()->getCanonicalURL();
+       }
 }
index 8fc0b77..1bf4f54 100644 (file)
  * ($wgProfiler['exclude']) containing an array of function names.
  * Shell-style patterns are also accepted.
  *
+ * It is also possible to use the Tideways PHP extension, which is mostly
+ * a drop-in replacement for Xhprof. Just change the XHPROF_FLAGS_* constants
+ * to TIDEWAYS_FLAGS_*.
+ *
  * @author Bryan Davis <bd808@wikimedia.org>
  * @copyright © 2014 Bryan Davis and Wikimedia Foundation.
  * @ingroup Profiler
  * @see Xhprof
  * @see https://php.net/xhprof
  * @see https://github.com/facebook/hhvm/blob/master/hphp/doc/profiling.md
+ * @see https://github.com/tideways/php-profiler-extension
  */
 class ProfilerXhprof extends Profiler {
        /**
diff --git a/includes/registration/ExtensionJsonValidationError.php b/includes/registration/ExtensionJsonValidationError.php
new file mode 100644 (file)
index 0000000..897d284
--- /dev/null
@@ -0,0 +1,22 @@
+<?php
+
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ */
+class ExtensionJsonValidationError extends Exception {
+}
diff --git a/includes/registration/ExtensionJsonValidator.php b/includes/registration/ExtensionJsonValidator.php
new file mode 100644 (file)
index 0000000..f6e76af
--- /dev/null
@@ -0,0 +1,122 @@
+<?php
+
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ */
+
+use Composer\Spdx\SpdxLicenses;
+use JsonSchema\Validator;
+
+/**
+ * @since 1.29
+ */
+class ExtensionJsonValidator {
+
+       /**
+        * @var callable
+        */
+       private $missingDepCallback;
+
+       /**
+        * @param callable $missingDepCallback
+        */
+       public function __construct( callable $missingDepCallback ) {
+               $this->missingDepCallback = $missingDepCallback;
+       }
+
+       /**
+        * @return bool
+        */
+       public function checkDependencies() {
+               if ( !class_exists( Validator::class ) ) {
+                       call_user_func( $this->missingDepCallback,
+                               'The JsonSchema library cannot be found, please install it through composer.'
+                       );
+                       return false;
+               } elseif ( !class_exists( SpdxLicenses::class ) ) {
+                       call_user_func( $this->missingDepCallback,
+                               'The spdx-licenses library cannot be found, please install it through composer.'
+                       );
+                       return false;
+               }
+
+               return true;
+       }
+
+       /**
+        * @param string $path file to validate
+        * @return bool true if passes validation
+        * @throws ExtensionJsonValidationError on any failure
+        */
+       public function validate( $path ) {
+               $data = json_decode( file_get_contents( $path ) );
+               if ( !is_object( $data ) ) {
+                       throw new ExtensionJsonValidationError( "$path is not valid JSON" );
+               }
+
+               if ( !isset( $data->manifest_version ) ) {
+                       throw new ExtensionJsonValidationError(
+                               "$path does not have manifest_version set." );
+               }
+
+               $version = $data->manifest_version;
+               if ( $version !== ExtensionRegistry::MANIFEST_VERSION ) {
+                       $schemaPath = __DIR__ . "/../../docs/extension.schema.v$version.json";
+               } else {
+                       $schemaPath = __DIR__ . '/../../docs/extension.schema.json';
+               }
+
+               // Not too old
+               if ( $version < ExtensionRegistry::OLDEST_MANIFEST_VERSION ) {
+                       throw new ExtensionJsonValidationError(
+                               "$path is using a non-supported schema version"
+                       );
+               } elseif ( $version > ExtensionRegistry::MANIFEST_VERSION ) {
+                       throw new ExtensionJsonValidationError(
+                               "$path is using a non-supported schema version"
+                       );
+               }
+
+               $licenseError = false;
+               // Check if it's a string, if not, schema validation will display an error
+               if ( isset( $data->{'license-name'} ) && is_string( $data->{'license-name'} ) ) {
+                       $licenses = new SpdxLicenses();
+                       $valid = $licenses->validate( $data->{'license-name'} );
+                       if ( !$valid ) {
+                               $licenseError = '[license-name] Invalid SPDX license identifier, '
+                                       . 'see <https://spdx.org/licenses/>';
+                       }
+               }
+
+               $validator = new Validator;
+               $validator->check( $data, (object)[ '$ref' => 'file://' . $schemaPath ] );
+               if ( $validator->isValid() && !$licenseError ) {
+                       // All good.
+                       return true;
+               } else {
+                       $out = "$path did pass validation.\n";
+                       foreach ( $validator->getErrors() as $error ) {
+                               $out .= "[{$error['property']}] {$error['message']}\n";
+                       }
+                       if ( $licenseError ) {
+                               $out .= "$licenseError\n";
+                       }
+                       throw new ExtensionJsonValidationError( $out );
+               }
+       }
+}
index 207f884..d967132 100644 (file)
@@ -141,6 +141,7 @@ class ExtensionProcessor implements Processor {
 
        /**
         * Things to be called once registration of these extensions are done
+        * keyed by the name of the extension that it belongs to
         *
         * @var callable[]
         */
@@ -180,11 +181,11 @@ class ExtensionProcessor implements Processor {
                $this->extractResourceLoaderModules( $dir, $info );
                $this->extractServiceWiringFiles( $dir, $info );
                $this->extractParserTestFiles( $dir, $info );
+               $name = $this->extractCredits( $path, $info );
                if ( isset( $info['callback'] ) ) {
-                       $this->callbacks[] = $info['callback'];
+                       $this->callbacks[$name] = $info['callback'];
                }
 
-               $this->extractCredits( $path, $info );
                foreach ( $info as $key => $val ) {
                        if ( in_array( $key, self::$globalSettings ) ) {
                                $this->storeToArray( $path, "wg$key", $val, $this->globals );
@@ -335,6 +336,7 @@ class ExtensionProcessor implements Processor {
        /**
         * @param string $path
         * @param array $info
+        * @return string Name of thing
         * @throws Exception
         */
        protected function extractCredits( $path, array $info ) {
@@ -360,6 +362,8 @@ class ExtensionProcessor implements Processor {
 
                $this->credits[$name] = $credits;
                $this->globals['wgExtensionCredits'][$credits['type']][] = $credits;
+
+               return $name;
        }
 
        /**
index b5c70e9..70dc624 100644 (file)
@@ -31,7 +31,7 @@ class ExtensionRegistry {
        /**
         * Bump whenever the registration cache needs resetting
         */
-       const CACHE_VERSION = 3;
+       const CACHE_VERSION = 4;
 
        /**
         * Special key that defines the merge strategy
@@ -59,6 +59,13 @@ class ExtensionRegistry {
         */
        protected $queued = [];
 
+       /**
+        * Whether we are done loading things
+        *
+        * @var bool
+        */
+       private $finished = false;
+
        /**
         * Items in the JSON file that aren't being
         * set as globals
@@ -114,12 +121,23 @@ class ExtensionRegistry {
                $this->queued[$path] = $mtime;
        }
 
+       /**
+        * @throws MWException If the queue is already marked as finished (no further things should
+        *  be loaded then).
+        */
        public function loadFromQueue() {
                global $wgVersion;
                if ( !$this->queued ) {
                        return;
                }
 
+               if ( $this->finished ) {
+                       throw new MWException(
+                               "The following paths tried to load late: "
+                               . implode( ', ', array_keys( $this->queued ) )
+                       );
+               }
+
                // A few more things to vary the cache on
                $versions = [
                        'registration' => self::CACHE_VERSION,
@@ -164,6 +182,15 @@ class ExtensionRegistry {
                $this->queued = [];
        }
 
+       /**
+        * After this is called, no more extensions can be loaded
+        *
+        * @since 1.29
+        */
+       public function finish() {
+               $this->finished = true;
+       }
+
        /**
         * Process a queue of extensions and return their extracted data
         *
@@ -285,9 +312,6 @@ class ExtensionRegistry {
                foreach ( $info['autoloaderPaths'] as $path ) {
                        require_once $path;
                }
-               foreach ( $info['callbacks'] as $cb ) {
-                       call_user_func( $cb );
-               }
 
                $this->loaded += $info['credits'];
                if ( $info['attributes'] ) {
@@ -297,6 +321,10 @@ class ExtensionRegistry {
                                $this->attributes = array_merge_recursive( $this->attributes, $info['attributes'] );
                        }
                }
+
+               foreach ( $info['callbacks'] as $name => $cb ) {
+                       call_user_func( $cb, $info['credits'][$name] );
+               }
        }
 
        /**
index 2d0d690..ab74dbd 100644 (file)
@@ -68,14 +68,14 @@ class RevDelArchiveItem extends RevDelRevisionItem {
        }
 
        protected function getRevisionLink() {
-               $date = htmlspecialchars( $this->list->getLanguage()->userTimeAndDate(
-                       $this->revision->getTimestamp(), $this->list->getUser() ) );
+               $date = $this->list->getLanguage()->userTimeAndDate(
+                       $this->revision->getTimestamp(), $this->list->getUser() );
 
                if ( $this->isDeleted() && !$this->canViewContent() ) {
-                       return $date;
+                       return htmlspecialchars( $date );
                }
 
-               return Linker::link(
+               return $this->getLinkRenderer()->makeLink(
                        SpecialPage::getTitleFor( 'Undelete' ),
                        $date,
                        [],
@@ -91,9 +91,9 @@ class RevDelArchiveItem extends RevDelRevisionItem {
                        return $this->list->msg( 'diff' )->escaped();
                }
 
-               return Linker::link(
+               return $this->getLinkRenderer()->makeLink(
                        SpecialPage::getTitleFor( 'Undelete' ),
-                       $this->list->msg( 'diff' )->escaped(),
+                       $this->list->msg( 'diff' )->text(),
                        [],
                        [
                                'target' => $this->list->title->getPrefixedText(),
index 52df2e3..decabba 100644 (file)
@@ -69,16 +69,16 @@ class RevDelArchivedFileItem extends RevDelFileItem {
        }
 
        protected function getLink() {
-               $date = htmlspecialchars( $this->list->getLanguage()->userTimeAndDate(
-                       $this->file->getTimestamp(), $this->list->getUser() ) );
+               $date = $this->list->getLanguage()->userTimeAndDate(
+                       $this->file->getTimestamp(), $this->list->getUser() );
 
                # Hidden files...
                if ( !$this->canViewContent() ) {
-                       $link = $date;
+                       $link = htmlspecialchars( $date );
                } else {
                        $undelete = SpecialPage::getTitleFor( 'Undelete' );
                        $key = $this->file->getKey();
-                       $link = Linker::link( $undelete, $date, [],
+                       $link = $this->getLinkRenderer()->makeLink( $undelete, $date, [],
                                [
                                        'target' => $this->list->title->getPrefixedText(),
                                        'file' => $key,
index ff01cee..06b596e 100644 (file)
@@ -116,19 +116,19 @@ class RevDelFileItem extends RevDelItem {
         * @return string
         */
        protected function getLink() {
-               $date = htmlspecialchars( $this->list->getLanguage()->userTimeAndDate(
-                       $this->file->getTimestamp(), $this->list->getUser() ) );
+               $date = $this->list->getLanguage()->userTimeAndDate(
+                       $this->file->getTimestamp(), $this->list->getUser() );
 
                if ( !$this->isDeleted() ) {
                        # Regular files...
-                       return Html::rawElement( 'a', [ 'href' => $this->file->getUrl() ], $date );
+                       return Html::element( 'a', [ 'href' => $this->file->getUrl() ], $date );
                }
 
                # Hidden files...
                if ( !$this->canViewContent() ) {
-                       $link = $date;
+                       $link = htmlspecialchars( $date );
                } else {
-                       $link = Linker::link(
+                       $link = $this->getLinkRenderer()->makeLink(
                                SpecialPage::getTitleFor( 'Revisiondelete' ),
                                $date,
                                [],
index 1ea7271..9e76f4c 100644 (file)
@@ -92,9 +92,9 @@ class RevDelLogItem extends RevDelItem {
                $formatter->setAudience( LogFormatter::FOR_THIS_USER );
 
                // Log link for this page
-               $loglink = Linker::link(
+               $loglink = $this->getLinkRenderer()->makeLink(
                        SpecialPage::getTitleFor( 'Log' ),
-                       $this->list->msg( 'log' )->escaped(),
+                       $this->list->msg( 'log' )->text(),
                        [],
                        [ 'page' => $title->getPrefixedText() ]
                );
index d799113..7fff366 100644 (file)
@@ -107,14 +107,14 @@ class RevDelRevisionItem extends RevDelItem {
         * @return string
         */
        protected function getRevisionLink() {
-               $date = htmlspecialchars( $this->list->getLanguage()->userTimeAndDate(
-                       $this->revision->getTimestamp(), $this->list->getUser() ) );
+               $date = $this->list->getLanguage()->userTimeAndDate(
+                       $this->revision->getTimestamp(), $this->list->getUser() );
 
                if ( $this->isDeleted() && !$this->canViewContent() ) {
-                       return $date;
+                       return htmlspecialchars( $date );
                }
 
-               return Linker::linkKnown(
+               return $this->getLinkRenderer()->makeKnownLink(
                        $this->list->title,
                        $date,
                        [],
@@ -134,9 +134,9 @@ class RevDelRevisionItem extends RevDelItem {
                if ( $this->isDeleted() && !$this->canViewContent() ) {
                        return $this->list->msg( 'diff' )->escaped();
                } else {
-                       return Linker::linkKnown(
+                       return $this->getLinkRenderer()->makeKnownLink(
                                        $this->list->title,
-                                       $this->list->msg( 'diff' )->escaped(),
+                                       $this->list->msg( 'diff' )->text(),
                                        [],
                                        [
                                                'diff' => $this->revision->getId(),
index e6763ca..69f2e49 100644 (file)
@@ -919,19 +919,18 @@ class SkinTemplate extends Skin {
                                        $content_navigation['views']['view']['redundant'] = true;
                                }
 
-                               $isForeignFile = $title->inNamespace( NS_FILE ) && $this->canUseWikiPage() &&
-                                       $this->getWikiPage() instanceof WikiFilePage && !$this->getWikiPage()->isLocal();
+                               $page = $this->canUseWikiPage() ? $this->getWikiPage() : false;
+                               $isRemoteContent = $page && !$page->isLocal();
 
                                // If it is a non-local file, show a link to the file in its own repository
                                // @todo abstract this for remote content that isn't a file
-                               if ( $isForeignFile ) {
-                                       $file = $this->getWikiPage()->getFile();
+                               if ( $isRemoteContent ) {
                                        $content_navigation['views']['view-foreign'] = [
                                                'class' => '',
                                                'text' => wfMessageFallback( "$skname-view-foreign", 'view-foreign' )->
                                                        setContext( $this->getContext() )->
-                                                       params( $file->getRepo()->getDisplayName() )->text(),
-                                               'href' => $file->getDescriptionUrl(),
+                                                       params( $page->getWikiDisplayName() )->text(),
+                                               'href' => $page->getSourceURL(),
                                                'primary' => false,
                                        ];
                                }
@@ -955,9 +954,9 @@ class SkinTemplate extends Skin {
                                                        && $title->getDefaultMessageText() !== false
                                                )
                                        ) {
-                                               $msgKey = $isForeignFile ? 'edit-local' : 'edit';
+                                               $msgKey = $isRemoteContent ? 'edit-local' : 'edit';
                                        } else {
-                                               $msgKey = $isForeignFile ? 'create-local' : 'create';
+                                               $msgKey = $isRemoteContent ? 'create-local' : 'create';
                                        }
                                        $content_navigation['views']['edit'] = [
                                                'class' => ( $isEditing && ( $section !== 'new' || !$showNewSection )
@@ -967,7 +966,7 @@ class SkinTemplate extends Skin {
                                                'text' => wfMessageFallback( "$skname-view-$msgKey", $msgKey )
                                                        ->setContext( $this->getContext() )->text(),
                                                'href' => $title->getLocalURL( $this->editUrlOptions() ),
-                                               'primary' => !$isForeignFile, // don't collapse this in vector
+                                               'primary' => !$isRemoteContent, // don't collapse this in vector
                                        ];
 
                                        // section link
index cb13840..2051948 100644 (file)
@@ -141,15 +141,20 @@ abstract class ChangesListSpecialPage extends SpecialPage {
 
                $opts->add( 'hideminor', false );
                $opts->add( 'hidebots', false );
+               $opts->add( 'hidehumans', false );
                $opts->add( 'hideanons', false );
                $opts->add( 'hideliu', false );
                $opts->add( 'hidepatrolled', false );
+               $opts->add( 'hideunpatrolled', false );
                $opts->add( 'hidemyself', false );
                $opts->add( 'hidebyothers', false );
 
                if ( $config->get( 'RCWatchCategoryMembership' ) ) {
                        $opts->add( 'hidecategorization', false );
                }
+               $opts->add( 'hidepageedits', false );
+               $opts->add( 'hidenewpages', false );
+               $opts->add( 'hidelog', false );
 
                $opts->add( 'namespace', '', FormOptions::INTNULL );
                $opts->add( 'invert', false );
@@ -235,8 +240,16 @@ abstract class ChangesListSpecialPage extends SpecialPage {
                if ( $opts['hidebots'] ) {
                        $conds['rc_bot'] = 0;
                }
-               if ( $user->useRCPatrol() && $opts['hidepatrolled'] ) {
-                       $conds['rc_patrolled'] = 0;
+               if ( $opts['hidehumans'] ) {
+                       $conds[] = 'rc_bot = 1';
+               }
+               if ( $user->useRCPatrol() ) {
+                       if ( $opts['hidepatrolled'] ) {
+                               $conds[] = 'rc_patrolled = 0';
+                       }
+                       if ( $opts['hideunpatrolled'] ) {
+                               $conds[] = 'rc_patrolled = 1';
+                       }
                }
                if ( $botsonly ) {
                        $conds['rc_bot'] = 1;
@@ -269,6 +282,15 @@ abstract class ChangesListSpecialPage extends SpecialPage {
                ) {
                        $conds[] = 'rc_type != ' . $dbr->addQuotes( RC_CATEGORIZE );
                }
+               if ( $opts['hidepageedits'] ) {
+                       $conds[] = 'rc_type != ' . $dbr->addQuotes( RC_EDIT );
+               }
+               if ( $opts['hidenewpages'] ) {
+                       $conds[] = 'rc_type != ' . $dbr->addQuotes( RC_NEW );
+               }
+               if ( $opts['hidelog'] ) {
+                       $conds[] = 'rc_type != ' . $dbr->addQuotes( RC_LOG );
+               }
 
                // Namespace filtering
                if ( $opts['namespace'] !== '' ) {
@@ -495,4 +517,23 @@ abstract class ChangesListSpecialPage extends SpecialPage {
        protected function getGroupName() {
                return 'changes';
        }
+
+       /**
+        * Get filters that can be rendered.
+        *
+        * Filters with 'msg' => false can be used to filter data but won't
+        * be presented as show/hide toggles in the UI. They are not returned
+        * by this function.
+        *
+        * @param array $allFilters Map of filter URL param names to properties (msg/default)
+        * @return array Map of filter URL param names to properties (msg/default)
+        */
+       protected function getRenderableCustomFilters( $allFilters ) {
+               return array_filter(
+                       $allFilters,
+                       function( $filter ) {
+                               return isset( $filter['msg'] ) && ( $filter['msg'] !== false );
+                       }
+               );
+       }
 }
index 74b474a..5448013 100644 (file)
@@ -77,6 +77,11 @@ class SpecialApiHelp extends UnlistedSpecialPage {
                $main = new ApiMain( $this->getContext(), false );
                try {
                        $module = $main->getModuleFromPath( $moduleName );
+               } catch ( ApiUsageException $ex ) {
+                       $this->getOutput()->addHTML( Html::rawElement( 'span', [ 'class' => 'error' ],
+                               $this->msg( 'apihelp-no-such-module', $moduleName )->inContentLanguage()->parse()
+                       ) );
+                       return;
                } catch ( UsageException $ex ) {
                        $this->getOutput()->addHTML( Html::rawElement( 'span', [ 'class' => 'error' ],
                                $this->msg( 'apihelp-no-such-module', $moduleName )->inContentLanguage()->parse()
index 3cd4d4d..40277ca 100644 (file)
@@ -492,7 +492,8 @@ class SpecialContributions extends IncludableSpecialPage {
                        $form .= "\t" . Html::hidden( $name, $value ) . "\n";
                }
 
-               $tagFilter = ChangeTags::buildTagFilterSelector( $this->opts['tagfilter'] );
+               $tagFilter = ChangeTags::buildTagFilterSelector(
+                       $this->opts['tagfilter'], false, $this->getContext() );
 
                if ( $tagFilter ) {
                        $filterSelection = Html::rawElement(
index ad12046..2936754 100644 (file)
  * @ingroup SpecialPage
  */
 class DeletedContributionsPage extends SpecialPage {
+       /** @var FormOptions */
+       protected $mOpts;
+
        function __construct() {
-               parent::__construct( 'DeletedContributions', 'deletedhistory',
-                       /*listed*/true, /*function*/false, /*file*/false );
+               parent::__construct( 'DeletedContributions', 'deletedhistory' );
        }
 
        /**
@@ -40,40 +42,43 @@ class DeletedContributionsPage extends SpecialPage {
        function execute( $par ) {
                $this->setHeaders();
                $this->outputHeader();
+               $this->checkPermissions();
 
                $user = $this->getUser();
 
-               if ( !$this->userCanExecute( $user ) ) {
-                       $this->displayRestrictionError();
-
-                       return;
-               }
-
-               $request = $this->getRequest();
                $out = $this->getOutput();
                $out->setPageTitle( $this->msg( 'deletedcontributions-title' ) );
 
-               $options = [];
+               $opts = new FormOptions();
+
+               $opts->add( 'target', '' );
+               $opts->add( 'namespace', '' );
+               $opts->add( 'limit', 20 );
+
+               $opts->fetchValuesFromRequest( $this->getRequest() );
+               $opts->validateIntBounds( 'limit', 0, $this->getConfig()->get( 'QueryPageDefaultLimit' ) );
 
                if ( $par !== null ) {
-                       $target = $par;
-               } else {
-                       $target = $request->getVal( 'target' );
+                       $opts->setValue( 'target', $par );
                }
 
+               $ns = $opts->getValue( 'namespace' );
+               if ( $ns !== null && $ns !== '' ) {
+                       $opts->setValue( 'namespace', intval( $ns ) );
+               }
+
+               $this->mOpts = $opts;
+
+               $target = $opts->getValue( 'target' );
                if ( !strlen( $target ) ) {
-                       $out->addHTML( $this->getForm( '' ) );
+                       $this->getForm();
 
                        return;
                }
 
-               $options['limit'] = $request->getInt( 'limit',
-                       $this->getConfig()->get( 'QueryPageDefaultLimit' ) );
-               $options['target'] = $target;
-
                $userObj = User::newFromName( $target, false );
                if ( !$userObj ) {
-                       $out->addHTML( $this->getForm( '' ) );
+                       $this->getForm();
 
                        return;
                }
@@ -82,16 +87,9 @@ class DeletedContributionsPage extends SpecialPage {
                $target = $userObj->getName();
                $out->addSubtitle( $this->getSubTitle( $userObj ) );
 
-               $ns = $request->getVal( 'namespace', null );
-               if ( $ns !== null && $ns !== '' ) {
-                       $options['namespace'] = intval( $ns );
-               } else {
-                       $options['namespace'] = '';
-               }
-
-               $out->addHTML( $this->getForm( $options ) );
+               $this->getForm();
 
-               $pager = new DeletedContribsPager( $this->getContext(), $target, $options['namespace'] );
+               $pager = new DeletedContribsPager( $this->getContext(), $target, $opts->getValue( 'namespace' ) );
                if ( !$pager->getNumRows() ) {
                        $out->addWikiMsg( 'nocontribs' );
 
@@ -187,76 +185,35 @@ class DeletedContributionsPage extends SpecialPage {
 
        /**
         * Generates the namespace selector form with hidden attributes.
-        * @param array $options The options to be included.
-        * @return string
         */
-       function getForm( $options ) {
-               $options['title'] = $this->getPageTitle()->getPrefixedText();
-               if ( !isset( $options['target'] ) ) {
-                       $options['target'] = '';
-               } else {
-                       $options['target'] = str_replace( '_', ' ', $options['target'] );
-               }
-
-               if ( !isset( $options['namespace'] ) ) {
-                       $options['namespace'] = '';
-               }
-
-               if ( !isset( $options['contribs'] ) ) {
-                       $options['contribs'] = 'user';
-               }
-
-               if ( $options['contribs'] == 'newbie' ) {
-                       $options['target'] = '';
-               }
-
-               $f = Xml::openElement( 'form', [ 'method' => 'get', 'action' => wfScript() ] );
-
-               foreach ( $options as $name => $value ) {
-                       if ( in_array( $name, [ 'namespace', 'target', 'contribs' ] ) ) {
-                               continue;
-                       }
-                       $f .= "\t" . Html::hidden( $name, $value ) . "\n";
-               }
+       function getForm() {
+               $opts = $this->mOpts;
+
+               $formDescriptor = [
+                       'target' => [
+                               'type' => 'user',
+                               'name' => 'target',
+                               'label-message' => 'sp-contributions-username',
+                               'default' => $opts->getValue( 'target' ),
+                               'ipallowed' => true,
+                       ],
 
-               $this->getOutput()->addModules( 'mediawiki.userSuggest' );
-
-               $f .= Xml::openElement( 'fieldset' );
-               $f .= Xml::element( 'legend', [], $this->msg( 'sp-contributions-search' )->text() );
-               $f .= Xml::tags(
-                       'label',
-                       [ 'for' => 'target' ],
-                       $this->msg( 'sp-contributions-username' )->parse()
-               ) . ' ';
-               $f .= Html::input(
-                       'target',
-                       $options['target'],
-                       'text',
-                       [
-                               'size' => '20',
-                               'required' => '',
-                               'class' => [
-                                       'mw-autocomplete-user', // used by mediawiki.userSuggest
-                               ],
-                       ] + ( $options['target'] ? [] : [ 'autofocus' ] )
-               ) . ' ';
-               $f .= Html::namespaceSelector(
-                       [
-                               'selected' => $options['namespace'],
+                       'namespace' => [
+                               'type' => 'namespaceselect',
+                               'name' => 'namespace',
+                               'label-message' => 'namespace',
                                'all' => '',
-                               'label' => $this->msg( 'namespace' )->text()
                        ],
-                       [
-                               'name' => 'namespace',
-                               'id' => 'namespace',
-                               'class' => 'namespaceselector',
-                       ]
-               ) . ' ';
-               $f .= Xml::submitButton( $this->msg( 'sp-contributions-submit' )->text() );
-               $f .= Xml::closeElement( 'fieldset' );
-               $f .= Xml::closeElement( 'form' );
-
-               return $f;
+               ];
+
+               $form = HTMLForm::factory( 'ooui', $formDescriptor, $this->getContext() )
+                       ->setWrapperLegendMsg( 'sp-contributions-search' )
+                       ->setSubmitTextMsg( 'sp-contributions-submit' )
+                       // prevent setting subpage and 'target' parameter at the same time
+                       ->setAction( $this->getPageTitle()->getLocalURL() )
+                       ->setMethod( 'get' )
+                       ->prepareForm()
+                       ->displayForm( false );
        }
 
        /**
index 9692dd0..085b68d 100644 (file)
@@ -307,7 +307,7 @@ class SpecialEmailUser extends UnlistedSpecialPage {
         * @since 1.20
         * @param array $data
         * @param HTMLForm $form
-        * @return Status|string|bool
+        * @return Status|bool
         */
        public static function uiSubmit( array $data, HTMLForm $form ) {
                return self::submit( $data, $form->getContext() );
@@ -320,8 +320,7 @@ class SpecialEmailUser extends UnlistedSpecialPage {
         *
         * @param array $data
         * @param IContextSource $context
-        * @return Status|string|bool Status object, or potentially a String on error
-        * or maybe even true on success if anything uses the EmailUser hook.
+        * @return Status|bool
         */
        public static function submit( array $data, IContextSource $context ) {
                $config = $context->getConfig();
@@ -329,7 +328,7 @@ class SpecialEmailUser extends UnlistedSpecialPage {
                $target = self::getTarget( $data['Target'] );
                if ( !$target instanceof User ) {
                        // Messages used here: notargettext, noemailtext, nowikiemailtext
-                       return $context->msg( $target . 'text' )->parseAsBlock();
+                       return Status::newFatal( $target . 'text' );
                }
 
                $to = MailAddress::newFromUser( $target );
@@ -342,9 +341,33 @@ class SpecialEmailUser extends UnlistedSpecialPage {
                $text .= $context->msg( 'emailuserfooter',
                        $from->name, $to->name )->inContentLanguage()->text();
 
-               $error = '';
+               $error = false;
                if ( !Hooks::run( 'EmailUser', [ &$to, &$from, &$subject, &$text, &$error ] ) ) {
-                       return $error;
+                       if ( $error instanceof Status ) {
+                               return $error;
+                       } elseif ( $error === false || $error === '' || $error === [] ) {
+                               // Possibly to tell HTMLForm to pretend there was no submission?
+                               return false;
+                       } elseif ( $error === true ) {
+                               // Hook sent the mail itself and indicates success?
+                               return Status::newGood();
+                       } elseif ( is_array( $error ) ) {
+                               $status = Status::newGood();
+                               foreach ( $error as $e ) {
+                                       $status->fatal( $e );
+                               }
+                               return $status;
+                       } elseif ( $error instanceof MessageSpecifier ) {
+                               return Status::newFatal( $error );
+                       } else {
+                               // Ugh. Either a raw HTML string, or something that's supposed
+                               // to be treated like one.
+                               $type = is_object( $error ) ? get_class( $error ) : gettype( $error );
+                               wfDeprecated( "EmailUser hook returning a $type as \$error", '1.29' );
+                               return Status::newFatal( new ApiRawMessage(
+                                       [ '$1', Message::rawParam( (string)$error ) ], 'hookaborted'
+                               ) );
+                       }
                }
 
                if ( $config->get( 'UserEmailUseReplyTo' ) ) {
index 66c5145..8530eb1 100644 (file)
@@ -95,7 +95,7 @@ class SpecialRecentChanges extends ChangesListSpecialPage {
        }
 
        /**
-        * Get custom show/hide filters
+        * Get all custom filters
         *
         * @return array Map of filter URL param names to properties (msg/default)
         */
@@ -501,7 +501,8 @@ class SpecialRecentChanges extends ChangesListSpecialPage {
                        $extraOpts['category'] = $this->categoryFilterForm( $opts );
                }
 
-               $tagFilter = ChangeTags::buildTagFilterSelector( $opts['tagfilter'] );
+               $tagFilter = ChangeTags::buildTagFilterSelector(
+                       $opts['tagfilter'], false, $this->getContext() );
                if ( count( $tagFilter ) ) {
                        $extraOpts['tagfilter'] = $tagFilter;
                }
@@ -746,9 +747,10 @@ class SpecialRecentChanges extends ChangesListSpecialPage {
 
                $showhide = [ 'show', 'hide' ];
 
-               foreach ( $this->getCustomFilters() as $key => $params ) {
+               foreach ( $this->getRenderableCustomFilters( $this->getCustomFilters() ) as $key => $params ) {
                        $filters[$key] = $params['msg'];
                }
+
                // Disable some if needed
                if ( !$user->useRCPatrol() ) {
                        unset( $filters['hidepatrolled'] );
index 326a1fa..4e683f6 100644 (file)
@@ -175,7 +175,7 @@ class SpecialUnblock extends SpecialPage {
         * @param array $data
         * @param IContextSource $context
         * @throws ErrorPageError
-        * @return array|bool Array(message key, parameters) on failure, True on success
+        * @return array|bool Array( Array( message key, parameters ) ) on failure, True on success
         */
        public static function processUnblock( array $data, IContextSource $context ) {
                $performer = $context->getUser();
@@ -211,7 +211,7 @@ class SpecialUnblock extends SpecialPage {
 
                # Delete block
                if ( !$block->delete() ) {
-                       return [ 'ipb_cant_unblock', htmlspecialchars( $block->getTarget() ) ];
+                       return [ [ 'ipb_cant_unblock', htmlspecialchars( $block->getTarget() ) ] ];
                }
 
                # Unset _deleted fields as needed
index 3ba46c1..1d9c057 100644 (file)
@@ -88,6 +88,10 @@ class UserrightsPage extends SpecialPage {
                        $this->mTarget = trim( $this->mTarget );
                }
 
+               if ( $this->mTarget !== null && User::getCanonicalName( $this->mTarget ) === $user->getName() ) {
+                       $this->isself = true;
+               }
+
                $fetchedStatus = $this->fetchUser( $this->mTarget, true );
                if ( $fetchedStatus->isOK() ) {
                        $this->mFetchedUser = $fetchedStatus->value;
index 4824961..55400d3 100644 (file)
@@ -130,7 +130,7 @@ class SpecialWatchlist extends ChangesListSpecialPage {
        }
 
        /**
-        * Get custom show/hide filters
+        * Get all custom filters
         *
         * @return array Map of filter URL param names to properties (msg/default)
         */
@@ -465,9 +465,10 @@ class SpecialWatchlist extends ChangesListSpecialPage {
                        $filters['hidecategorization'] = 'wlshowhidecategorization';
                }
 
-               foreach ( $this->getCustomFilters() as $key => $params ) {
+               foreach ( $this->getRenderableCustomFilters( $this->getCustomFilters() ) as $key => $params ) {
                        $filters[$key] = $params['msg'];
                }
+
                // Disable some if needed
                if ( !$user->useRCPatrol() ) {
                        unset( $filters['hidepatrolled'] );
index 5609310..efc51ef 100644 (file)
@@ -25,6 +25,8 @@
  *
  * @ingroup Pager
  */
+use MediaWiki\MediaWikiServices;
+
 class AllMessagesTablePager extends TablePager {
 
        protected $filter, $prefix, $langcode, $displayPrefix;
@@ -297,6 +299,7 @@ class AllMessagesTablePager extends TablePager {
        }
 
        function formatValue( $field, $value ) {
+               $linkRenderer = MediaWikiServices::getInstance()->getLinkRenderer();
                switch ( $field ) {
                        case 'am_title' :
                                $title = Title::makeTitle( NS_MEDIAWIKI, $value . $this->suffix );
@@ -313,25 +316,19 @@ class AllMessagesTablePager extends TablePager {
                                );
 
                                if ( $this->mCurrentRow->am_customised ) {
-                                       $title = Linker::linkKnown( $title, $this->getLanguage()->lcfirst( $value ) );
+                                       $title = $linkRenderer->makeKnownLink( $title, $this->getLanguage()->lcfirst( $value ) );
                                } else {
-                                       $title = Linker::link(
+                                       $title = $linkRenderer->makeBrokenLink(
                                                $title,
-                                               $this->getLanguage()->lcfirst( $value ),
-                                               [],
-                                               [],
-                                               [ 'broken' ]
+                                               $this->getLanguage()->lcfirst( $value )
                                        );
                                }
                                if ( $this->mCurrentRow->am_talk_exists ) {
-                                       $talk = Linker::linkKnown( $talk, $this->talk );
+                                       $talk = $linkRenderer->makeKnownLink( $talk, $this->talk );
                                } else {
-                                       $talk = Linker::link(
+                                       $talk = $linkRenderer->makeBrokenLink(
                                                $talk,
-                                               $this->talk,
-                                               [],
-                                               [],
-                                               [ 'broken' ]
+                                               $this->talk
                                        );
                                }
 
index d822976..a4124db 100644 (file)
@@ -22,6 +22,8 @@
 /**
  * @ingroup Pager
  */
+use MediaWiki\MediaWikiServices;
+
 class BlockListPager extends TablePager {
 
        protected $conds;
@@ -72,7 +74,7 @@ class BlockListPager extends TablePager {
                        ];
 
                        foreach ( $keys as $key ) {
-                               $msg[$key] = $this->msg( $key )->escaped();
+                               $msg[$key] = $this->msg( $key )->text();
                        }
                }
 
@@ -83,6 +85,8 @@ class BlockListPager extends TablePager {
 
                $formatted = '';
 
+               $linkRenderer = MediaWikiServices::getInstance()->getLinkRenderer();
+
                switch ( $name ) {
                        case 'ipb_timestamp':
                                $formatted = htmlspecialchars( $language->userTimeAndDate( $value, $this->getUser() ) );
@@ -117,18 +121,18 @@ class BlockListPager extends TablePager {
                                ) );
                                if ( $this->getUser()->isAllowed( 'block' ) ) {
                                        if ( $row->ipb_auto ) {
-                                               $links[] = Linker::linkKnown(
+                                               $links[] = $linkRenderer->makeKnownLink(
                                                        SpecialPage::getTitleFor( 'Unblock' ),
                                                        $msg['unblocklink'],
                                                        [],
                                                        [ 'wpTarget' => "#{$row->ipb_id}" ]
                                                );
                                        } else {
-                                               $links[] = Linker::linkKnown(
+                                               $links[] = $linkRenderer->makeKnownLink(
                                                        SpecialPage::getTitleFor( 'Unblock', $row->ipb_address ),
                                                        $msg['unblocklink']
                                                );
-                                               $links[] = Linker::linkKnown(
+                                               $links[] = $linkRenderer->makeKnownLink(
                                                        SpecialPage::getTitleFor( 'Block', $row->ipb_address ),
                                                        $msg['change-blocklink']
                                                );
@@ -174,21 +178,21 @@ class BlockListPager extends TablePager {
                        case 'ipb_params':
                                $properties = [];
                                if ( $row->ipb_anon_only ) {
-                                       $properties[] = $msg['anononlyblock'];
+                                       $properties[] = htmlspecialchars( $msg['anononlyblock'] );
                                }
                                if ( $row->ipb_create_account ) {
-                                       $properties[] = $msg['createaccountblock'];
+                                       $properties[] = htmlspecialchars( $msg['createaccountblock'] );
                                }
                                if ( $row->ipb_user && !$row->ipb_enable_autoblock ) {
-                                       $properties[] = $msg['noautoblockblock'];
+                                       $properties[] = htmlspecialchars( $msg['noautoblockblock'] );
                                }
 
                                if ( $row->ipb_block_email ) {
-                                       $properties[] = $msg['emailblock'];
+                                       $properties[] = htmlspecialchars( $msg['emailblock'] );
                                }
 
                                if ( !$row->ipb_allow_usertalk ) {
-                                       $properties[] = $msg['blocklist-nousertalk'];
+                                       $properties[] = htmlspecialchars( $msg['blocklist-nousertalk'] );
                                }
 
                                $formatted = $language->commaList( $properties );
index a145e45..39c55c8 100644 (file)
@@ -23,6 +23,8 @@
  * Pager for Special:Contributions
  * @ingroup Pager
  */
+use MediaWiki\MediaWikiServices;
+
 class ContribsPager extends ReverseChronologicalPager {
 
        public $mDefaultDirection = IndexPager::DIR_DESCENDING;
@@ -347,6 +349,8 @@ class ContribsPager extends ReverseChronologicalPager {
                $ret = '';
                $classes = [];
 
+               $linkRenderer = MediaWikiServices::getInstance()->getLinkRenderer();
+
                /*
                 * There may be more than just revision rows. To make sure that we'll only be processing
                 * revisions here, let's _try_ to build a revision out of our row (without displaying
@@ -367,9 +371,9 @@ class ContribsPager extends ReverseChronologicalPager {
                        $classes = [];
 
                        $page = Title::newFromRow( $row );
-                       $link = Linker::link(
+                       $link = $linkRenderer->makeLink(
                                $page,
-                               htmlspecialchars( $page->getPrefixedText() ),
+                               $page->getPrefixedText(),
                                [ 'class' => 'mw-contributions-title' ],
                                $page->isRedirect() ? [ 'redirect' => 'no' ] : []
                        );
@@ -389,9 +393,9 @@ class ContribsPager extends ReverseChronologicalPager {
                        }
                        # Is there a visible previous revision?
                        if ( $rev->userCan( Revision::DELETED_TEXT, $user ) && $rev->getParentId() !== 0 ) {
-                               $difftext = Linker::linkKnown(
+                               $difftext = $linkRenderer->makeKnownLink(
                                        $page,
-                                       $this->messages['diff'],
+                                       new HtmlArmor( $this->messages['diff'] ),
                                        [],
                                        [
                                                'diff' => 'prev',
@@ -401,9 +405,9 @@ class ContribsPager extends ReverseChronologicalPager {
                        } else {
                                $difftext = $this->messages['diff'];
                        }
-                       $histlink = Linker::linkKnown(
+                       $histlink = $linkRenderer->makeKnownLink(
                                $page,
-                               $this->messages['hist'],
+                               new HtmlArmor( $this->messages['hist'] ),
                                [],
                                [ 'action' => 'history' ]
                        );
@@ -434,9 +438,9 @@ class ContribsPager extends ReverseChronologicalPager {
                        $comment = $lang->getDirMark() . Linker::revComment( $rev, false, true );
                        $date = $lang->userTimeAndDate( $row->rev_timestamp, $user );
                        if ( $rev->userCan( Revision::DELETED_TEXT, $user ) ) {
-                               $d = Linker::linkKnown(
+                               $d = $linkRenderer->makeKnownLink(
                                        $page,
-                                       htmlspecialchars( $date ),
+                                       $date,
                                        [ 'class' => 'mw-changeslist-date' ],
                                        [ 'oldid' => intval( $row->rev_id ) ]
                                );
index 1acbba1..9ffcce9 100644 (file)
@@ -22,6 +22,8 @@
 /**
  * @ingroup Pager
  */
+use MediaWiki\MediaWikiServices;
+
 class DeletedContribsPager extends IndexPager {
 
        public $mDefaultDirection = IndexPager::DIR_DESCENDING;
@@ -39,7 +41,7 @@ class DeletedContribsPager extends IndexPager {
                parent::__construct( $context );
                $msgs = [ 'deletionlog', 'undeleteviewlink', 'diff' ];
                foreach ( $msgs as $msg ) {
-                       $this->messages[$msg] = $this->msg( $msg )->escaped();
+                       $this->messages[$msg] = $this->msg( $msg )->text();
                }
                $this->target = $target;
                $this->namespace = $namespace;
@@ -240,6 +242,8 @@ class DeletedContribsPager extends IndexPager {
        function formatRevisionRow( $row ) {
                $page = Title::makeTitle( $row->ar_namespace, $row->ar_title );
 
+               $linkRenderer = MediaWikiServices::getInstance()->getLinkRenderer();
+
                $rev = new Revision( [
                        'title' => $page,
                        'id' => $row->ar_rev_id,
@@ -254,7 +258,7 @@ class DeletedContribsPager extends IndexPager {
                $undelete = SpecialPage::getTitleFor( 'Undelete' );
 
                $logs = SpecialPage::getTitleFor( 'Log' );
-               $dellog = Linker::linkKnown(
+               $dellog = $linkRenderer->makeKnownLink(
                        $logs,
                        $this->messages['deletionlog'],
                        [],
@@ -264,7 +268,7 @@ class DeletedContribsPager extends IndexPager {
                        ]
                );
 
-               $reviewlink = Linker::linkKnown(
+               $reviewlink = $linkRenderer->makeKnownLink(
                        SpecialPage::getTitleFor( 'Undelete', $page->getPrefixedDBkey() ),
                        $this->messages['undeleteviewlink']
                );
@@ -272,7 +276,7 @@ class DeletedContribsPager extends IndexPager {
                $user = $this->getUser();
 
                if ( $user->isAllowed( 'deletedtext' ) ) {
-                       $last = Linker::linkKnown(
+                       $last = $linkRenderer->makeKnownLink(
                                $undelete,
                                $this->messages['diff'],
                                [],
@@ -283,17 +287,16 @@ class DeletedContribsPager extends IndexPager {
                                ]
                        );
                } else {
-                       $last = $this->messages['diff'];
+                       $last = htmlspecialchars( $this->messages['diff'] );
                }
 
                $comment = Linker::revComment( $rev );
                $date = $this->getLanguage()->userTimeAndDate( $rev->getTimestamp(), $user );
-               $date = htmlspecialchars( $date );
 
                if ( !$user->isAllowed( 'undelete' ) || !$rev->userCan( Revision::DELETED_TEXT, $user ) ) {
-                       $link = $date; // unusable link
+                       $link = htmlspecialchars( $date ); // unusable link
                } else {
-                       $link = Linker::linkKnown(
+                       $link = $linkRenderer->makeKnownLink(
                                $undelete,
                                $date,
                                [ 'class' => 'mw-changeslist-date' ],
@@ -308,7 +311,7 @@ class DeletedContribsPager extends IndexPager {
                        $link = '<span class="history-deleted">' . $link . '</span>';
                }
 
-               $pagelink = Linker::link(
+               $pagelink = $linkRenderer->makeLink(
                        $page,
                        null,
                        [ 'class' => 'mw-changeslist-title' ]
index 7fc4a95..59dea02 100644 (file)
@@ -22,6 +22,8 @@
 /**
  * @ingroup Pager
  */
+use MediaWiki\MediaWikiServices;
+
 class ImageListPager extends TablePager {
 
        protected $mFieldNames = null;
@@ -422,6 +424,7 @@ class ImageListPager extends TablePager {
         * @throws MWException
         */
        function formatValue( $field, $value ) {
+               $linkRenderer = MediaWikiServices::getInstance()->getLinkRenderer();
                switch ( $field ) {
                        case 'thumb':
                                $opt = [ 'time' => wfTimestamp( TS_MW, $this->mCurrentRow->img_timestamp ) ];
@@ -449,9 +452,9 @@ class ImageListPager extends TablePager {
                                // Weird files can maybe exist? Bug 22227
                                $filePage = Title::makeTitleSafe( NS_FILE, $value );
                                if ( $filePage ) {
-                                       $link = Linker::linkKnown(
+                                       $link = $linkRenderer->makeKnownLink(
                                                $filePage,
-                                               htmlspecialchars( $filePage->getText() )
+                                               $filePage->getText()
                                        );
                                        $download = Xml::element( 'a',
                                                [ 'href' => wfLocalFile( $filePage )->getUrl() ],
@@ -462,9 +465,9 @@ class ImageListPager extends TablePager {
                                        // Add delete links if allowed
                                        // From https://github.com/Wikia/app/pull/3859
                                        if ( $filePage->userCan( 'delete', $this->getUser() ) ) {
-                                               $deleteMsg = $this->msg( 'listfiles-delete' )->escaped();
+                                               $deleteMsg = $this->msg( 'listfiles-delete' )->text();
 
-                                               $delete = Linker::linkKnown(
+                                               $delete = $linkRenderer->makeKnownLink(
                                                        $filePage, $deleteMsg, [], [ 'action' => 'delete' ]
                                                );
                                                $delete = $this->msg( 'parentheses' )->rawParams( $delete )->escaped();
@@ -479,9 +482,9 @@ class ImageListPager extends TablePager {
                        case 'img_user_text':
                                if ( $this->mCurrentRow->img_user ) {
                                        $name = User::whoIs( $this->mCurrentRow->img_user );
-                                       $link = Linker::link(
+                                       $link = $linkRenderer->makeLink(
                                                Title::makeTitle( NS_USER, $name ),
-                                               htmlspecialchars( $name )
+                                               $name
                                        );
                                } else {
                                        $link = htmlspecialchars( $value );
index a15d910..4594385 100644 (file)
@@ -3110,7 +3110,6 @@ public static $zh2Hant = [
 '一干部下' => '一干部下',
 '一年' => '一年',
 '一年里' => '一年裡',
-'一别头' => '一彆頭',
 '一斗斗' => '一斗斗',
 '一树百获' => '一樹百穫',
 '一准' => '一準',
@@ -3342,7 +3341,6 @@ public static $zh2Hant = [
 '干嚎' => '乾嚎',
 '干回付' => '乾回付',
 '干圆洁净' => '乾圓潔淨',
-'干地' => '乾地',
 '干坞' => '乾塢',
 '干女' => '乾女',
 '干奴才' => '乾奴才',
@@ -4124,6 +4122,8 @@ public static $zh2Hant = [
 '划過' => '划過',
 '划龍舟' => '划龍舟',
 '划龙舟' => '划龍舟',
+'划龍船' => '划龍船',
+'划龙船' => '划龍船',
 '判断发' => '判斷發',
 '别辟' => '別闢',
 '利欲' => '利慾',
@@ -4430,7 +4430,6 @@ public static $zh2Hant = [
 '吸干' => '吸乾',
 '吹干' => '吹乾',
 '吹发' => '吹髮',
-'吹胡' => '吹鬍',
 '吾为之范我驰驱' => '吾爲之範我馳驅',
 '吕后' => '呂后',
 '呂后' => '呂后',
@@ -4460,6 +4459,8 @@ public static $zh2Hant = [
 '哀挽' => '哀輓',
 '品鉴' => '品鑑',
 '哄堂大笑' => '哄堂大笑',
+'哈啰喂' => '哈囉喂',
+'哈囉喂' => '哈囉喂',
 '員山庄' => '員山庄',
 '哪里' => '哪裡',
 '唁吊' => '唁弔',
@@ -4483,7 +4484,6 @@ public static $zh2Hant = [
 '喂!' => '喂!',
 '喂,' => '喂,',
 '善于' => '善於',
-'喜向往' => '喜向往',
 '喜欢表' => '喜歡錶',
 '喜欢钟' => '喜歡鐘',
 '喜欢钟表' => '喜歡鐘錶',
@@ -4494,6 +4494,8 @@ public static $zh2Hant = [
 '乔岳' => '喬嶽',
 '单于' => '單于',
 '單于' => '單于',
+'单向' => '單向',
+'單向' => '單向',
 '单单于' => '單單於',
 '单干' => '單幹',
 '单打独斗' => '單打獨鬥',
@@ -4583,7 +4585,6 @@ public static $zh2Hant = [
 '在于' => '在於',
 '地图里' => '地圖裡',
 '地心历表' => '地心曆表',
-'地方志' => '地方志',
 '地志' => '地誌',
 '地丑德齐' => '地醜德齊',
 '坏于' => '坏於',
@@ -4722,7 +4723,6 @@ public static $zh2Hant = [
 '天后宫' => '天后宮',
 '天地志狼' => '天地志狼',
 '天地为范' => '天地為範',
-'天干地支' => '天干地支',
 '天后来' => '天後來',
 '天后半' => '天後半',
 '天后天' => '天後天',
@@ -4866,7 +4866,6 @@ public static $zh2Hant = [
 '封為后' => '封為后',
 '封面里' => '封面裡',
 '射雕' => '射鵰',
-'专向往' => '專向往',
 '专辑里' => '專輯裡',
 '尊后' => '尊后',
 '对不准' => '對不準',
@@ -4947,6 +4946,7 @@ public static $zh2Hant = [
 '山里的' => '山裡的',
 '山谷' => '山谷',
 '山重水复' => '山重水複',
+'岩松了' => '岩松了',
 '岫岩' => '岫巖',
 '岱岳' => '岱嶽',
 '峇里海' => '峇里海',
@@ -5011,6 +5011,7 @@ public static $zh2Hant = [
 '年代里' => '年代裡',
 '年历' => '年曆',
 '年历史' => '年歷史',
+'年历次' => '年歷次',
 '年谷' => '年穀',
 '年里' => '年裡',
 '年鉴' => '年鑑',
@@ -5166,8 +5167,6 @@ public static $zh2Hant = [
 '强奸' => '強姦',
 '强干' => '強幹',
 '强于' => '強於',
-'别口气' => '彆口氣',
-'别强' => '彆強',
 '别扭' => '彆扭',
 '别拗' => '彆拗',
 '别气' => '彆氣',
@@ -5403,6 +5402,7 @@ public static $zh2Hant = [
 '怠于' => '怠於',
 '急于' => '急於',
 '急冲而下' => '急衝而下',
+'性别扭曲' => '性別扭曲',
 '性征' => '性徵',
 '性欲' => '性慾',
 '怨气冲天' => '怨氣衝天',
@@ -5573,7 +5573,6 @@ public static $zh2Hant = [
 '抓奸' => '抓姦',
 '抓斗' => '抓鬥',
 '抗御' => '抗禦',
-'折向往' => '折向往',
 '折子戏' => '折子戲',
 '折子戲' => '折子戲',
 '折戟沈河' => '折戟沈河',
@@ -5682,6 +5681,7 @@ public static $zh2Hant = [
 '卷款' => '捲款',
 '卷毛' => '捲毛',
 '卷烟盒' => '捲煙盒',
+'卷瓣' => '捲瓣',
 '卷积云' => '捲積雲',
 '卷筒' => '捲筒',
 '卷帘' => '捲簾',
@@ -5927,10 +5927,8 @@ public static $zh2Hant = [
 '断发' => '斷髮',
 '断发文身' => '斷髮文身',
 '方便面' => '方便麵',
-'方向往' => '方向往',
-'方志恒' => '方志恒',
+'方向' => '方向',
 '方法里' => '方法裡',
-'方志' => '方誌',
 '于后' => '於後',
 '于征' => '於徵',
 '于海上' => '於海上',
@@ -6625,6 +6623,7 @@ public static $zh2Hant = [
 '煮面' => '煮麵',
 '熊杰' => '熊杰',
 '荧郁' => '熒鬱',
+'熬制' => '熬製',
 '炖制' => '燉製',
 '燎发' => '燎髮',
 '烧干' => '燒乾',
@@ -6791,7 +6790,6 @@ public static $zh2Hant = [
 '白里透红' => '白裡透紅',
 '白面包青天' => '白面包青天',
 '白发' => '白髮',
-'白胡' => '白鬍',
 '白霉' => '白黴',
 '百个' => '百個',
 '百只可' => '百只可',
@@ -6836,7 +6834,6 @@ public static $zh2Hant = [
 '皮里阳秋' => '皮裡陽秋',
 '皮制' => '皮製',
 '皮松' => '皮鬆',
-'皱别' => '皺彆',
 '皱折' => '皺摺',
 '盆吊' => '盆弔',
 '盈余' => '盈餘',
@@ -7224,7 +7221,6 @@ public static $zh2Hant = [
 '编码表' => '編碼表',
 '编钟' => '編鐘',
 '编余' => '編餘',
-'编发' => '編髮',
 '缓征' => '緩徵',
 '缓冲' => '緩衝',
 '致密' => '緻密',
@@ -7272,6 +7268,7 @@ public static $zh2Hant = [
 '系紧' => '繫緊',
 '系绳' => '繫繩',
 '系累' => '繫纍',
+'系膜' => '繫膜',
 '系舟' => '繫舟',
 '系船' => '繫船',
 '系辞' => '繫辭',
@@ -7468,7 +7465,6 @@ public static $zh2Hant = [
 '艸木丰丰' => '艸木丰丰',
 '芒果干' => '芒果乾',
 '花不要采' => '花不要採',
-'花卷' => '花捲',
 '花盆里' => '花盆裡',
 '花菴词选' => '花菴詞選',
 '花药' => '花葯',
@@ -7851,7 +7847,10 @@ public static $zh2Hant = [
 '西昆' => '西崑',
 '西岳' => '西嶽',
 '西历' => '西曆',
+'西历代' => '西歷代',
+'西历任' => '西歷任',
 '西历史' => '西歷史',
+'西历次' => '西歷次',
 '西湖里' => '西湖里',
 '西西里' => '西西里',
 '西谷米' => '西谷米',
@@ -8154,7 +8153,8 @@ public static $zh2Hant = [
 '轻松松' => '輕鬆鬆',
 '轮奸' => '輪姦',
 '轮回' => '輪迴',
-'转向往' => '轉向往',
+'轉向' => '轉向',
+'转向' => '轉向',
 '转托' => '轉託',
 '转斗千里' => '轉鬥千里',
 '辛丑' => '辛丑',
@@ -8627,7 +8627,6 @@ public static $zh2Hant = [
 '长发公主' => '長髮公主',
 '长发妹' => '長髮妹',
 '长发姑娘' => '長髮姑娘',
-'长胡' => '長鬍',
 '门帘' => '門帘',
 '门吊儿' => '門弔兒',
 '门里' => '門裡',
@@ -13453,6 +13452,7 @@ public static $zh2Hans = [
 '以微知著' => '以微知著',
 '仰屋著書' => '仰屋著书',
 '彷彿' => '仿佛',
+'伊東豊雄' => '伊东丰雄',
 '夥計' => '伙计',
 '佛頭著糞' => '佛头著粪',
 '偵蒐' => '侦搜',
index 9a8c749..f6c6636 100644 (file)
        "userrights-user-editname": "أدخل اسم مستخدم:",
        "editusergroup": "تحميل مجموعات المستخدم",
        "editinguser": "تغيير صلاحيات {{GENDER:$1|المستخدم|المستخدمة}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "عرض صلاحيات المستخدم {{GENDER:$1|للمستخدم|للمستخدمة}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "تعديل مجموعات المستخدم",
+       "userrights-viewusergroup": "عرض مجموعات المستخدم",
        "saveusergroups": "احفظ مجموعات {{GENDER:$1|المستخدم|المستخدمة}}",
        "userrights-groupsmember": "عضو في:",
        "userrights-groupsmember-auto": "عضو ضمني في:",
        "action-upload_by_url": "رفع هذا الملف من عنوان مسار",
        "action-writeapi": "استخدام API الكتابة",
        "action-delete": "حذف هذه الصفحة",
-       "action-deleterevision": "حذف هذه المراجعة",
-       "action-deletedhistory": "رؤية تاريخ هذه الصفحة المحذوف",
+       "action-deleterevision": "حذف المراجعات",
+       "action-deletelogentry": "حذف مدخلات السجل",
+       "action-deletedhistory": "رؤية تاريخ الصفحات المحذوف",
+       "action-deletedtext": "رؤية تاريخ المراجعات المحذوف",
        "action-browsearchive": "البحث في الصفحات المحذوفة",
-       "action-undelete": "استرجاع هذه الصفحة",
-       "action-suppressrevision": "مراجعة واسترجاع هذه المراجعة المخفية",
+       "action-undelete": "استرجاع الصفحات",
+       "action-suppressrevision": "مراجعة واسترجاع المراجعات المخفية",
        "action-suppressionlog": "رؤية هذا السجل الخاص",
        "action-block": "منع هذا المستخدم من التعديل",
        "action-protect": "تغيير مستويات الحماية لهذه الصفحة",
        "action-userrights-interwiki": "تعديل صلاحيات المستخدم للمستخدمين في الويكيات الأخرى",
        "action-siteadmin": "غلق أو رفع غلق قاعدة البيانات",
        "action-sendemail": "إرسال رسائل بريد إلكتروني",
+       "action-editmyoptions": "تعديل تفضيلاتك",
        "action-editmywatchlist": "تعديل قائمة مراقبتك",
        "action-viewmywatchlist": "مشاهدة قائمة مراقبتك",
        "action-viewmyprivateinfo": "مشاهدة معلوماتك الخاصة",
        "emailccsubject": "نسخة من رسالتك إلى $1: $2",
        "emailsent": "أُرسل البريد الإلكتروني",
        "emailsenttext": "أُرسلت رسالتك الإلكترونية.",
-       "emailuserfooter": "هذا البريد الإلكتروني {{GENDER:$1|تم إرساله}} بواسطة $1 إلى {{GENDER:$2|$2}} بواسطة وظيفة \"{{int:emailuser}}\" في {{SITENAME}}.",
+       "emailuserfooter": "هذا البريد الإلكتروني {{GENDER:$1|تم إرساله}} بواسطة $1 إلى {{GENDER:$2|$2}} بواسطة وظيفة \"{{int:emailuser}}\" في {{SITENAME}}. عنوان البريد الخاص {{GENDER:$2|بك}} سيتم إرساله مباشرة {{GENDER:$1|للمرسل الأصلي|للمرسلة الأصلية}}، مما يكشف عنوان البريد الإلكتروني الخاص {{GENDER:$2|بك}} {{GENDER:$1|لهم}}.",
        "usermessage-summary": "ترك رسالة نظام.",
        "usermessage-editor": "مراسل النظام",
        "watchlist": "قائمة مراقبتي",
        "usercssispublic": "من فضل لاحظ: صفحات الCSS الفرعية لا ينبغي أن تحتوي على بيانات سرية بما أنها يمكن رؤيتها بواسطة المستخدمين الآخرين.",
        "restrictionsfield-badip": "عنوان أيبي أو نطاق غير صحيح: $1",
        "restrictionsfield-label": "نطاقات الأيبي المسموح بها:",
-       "restrictionsfield-help": "عنوان أيبي أو نطاق CIDR واحد لكل سطر. لتفعيل كل شيء، استخدم<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "عنوان أيبي أو نطاق CIDR واحد لكل سطر. لتفعيل كل شيء، استخدم<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "pageid": "معرف الصفحة $1"
 }
index fcaa1bb..d06e28e 100644 (file)
        "accmailtext": "[[User talk:$1|$1]] اوچون بیر راست‌گله رمز یارادیلیب و $2-ه گؤندریلدی.\n\nبو یئنی حسابین رمزی، گیرندن سونرا <em>[[Special:ChangePassword|رمز دَییشدیرمه]]</em> صحیفه‌سیندن دَییشیله بیلر.",
        "newarticle": "(یئنی)",
        "newarticletext": "مووجود اوْلمايان صفحه‌‌يه اوْلان لینکی ایزله‌دینیز. \nآشاغیداکی یئره یازیلارینیزی يازیب، بۇ صفحه‌‌نی '''سیز''' يارادا بیلرسینیز. (آرتیق معلومات اۆچون [$1 کؤمک صفحه‌‌سینه] باخین). اگر بۇ صفحه‌‌يه ایشتباه گلمیسینیزسه تکجه براوزرین '''قایید''' دۆيمه‌سینه وۇرون.",
-       "anontalkpagetext": "''بو صحیفه قئیدیات‌دان کئچممیش و یا داخیل اولمامیش آنونیم ایستیفادچییه عایید موذاکیره صحیفه‌سی‌دیر.\nاونا گؤره بو ایستیفادچینی رقم‌لردن عبارت ایپ اونوانی ایله معین ائتمک مجبوریتیندییک.\nبئله ایپ اونوان بیر نئچه فرد طرفین‌دن ایستیفاده‌ده اولا بیلر.\nاگر سیز آنونیم ایستیفادچیسینیزسه و بو مئساژین سیزه عایید اولمادیغینی دوشونورسونوزسه، اوندا  [[Special:CreateAccount|قئیدیات‌دان کئچین]] و یا [[Special:UserLogin|داخی اولون]].''",
+       "anontalkpagetext": "----<em>بو صفحه حسابسیز و یا سیستمه گیرمه میش تانیلماز ایشلدنه مربوط دانیشیق صفحه‌سی‌دیر.\nاونا گؤره بو ایشلدنی رقم‌لردن عبارت ایپی آدرسی ایله بللیلشدیریلیبدیر.</em>\nبئله آیپی آدرسی بیر نئچه فرد طرفین‌دن ایستیفاده‌ده اولا بیلر.\nاگر سیز تانیلماز ایشلدنسینیز و بو پیامین سیزه مربوط اولمادیغینی دوشونورسونوزسه، اوندا  [[Special:CreateAccount|حساب یارادین]] و یا [[Special:UserLogin|سیستمه گیرین]].''",
        "noarticletext": "ایندی بو صفحه‌ده یازی یوخدور.\nسیز آیری صفحه‌‌لرده [[Special:Search/{{PAGENAME}}|بو باشلیق اوچون آختارا بیلرسیز]]،\nیا دا <span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} باغلی قئیدلری آختارا بیلرسیز]،\nیا دا [{{fullurl:{{FULLPAGENAME}}|action=edit}} بو صفحه‌نی دَییشدیره بیلرسیز]</span>.",
        "noarticletext-nopermission": "بو صحیفه‌‌ ایندی بوشدور. \nباشقا صحیفه‌‌لرده عینی آددا صحیفه‌‌نی  [[Special:Search/{{PAGENAME}}| آختار]], علاقه‌‌لی قئيدلره \n<span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} باخا],\nو يا صحیفه‌‌نی  [{{fullurl:{{FULLPAGENAME}}|action=edit}} redaktə]</span> ائده بیلرسینیز.",
        "missing-revision": "«{{FULLPAGENAME}}» صحیفه‌سی اوچون $1 نومره‌لی نوسخه یوخدور.\n\nعموماُ بو ایشکال، واختی گئچمیش بیر باغلانتی ایله سیلینمیش بیر صحیفه‌یه گلنده، قاباغا گلر.\n[{{fullurl:{{#Special:Log}}/delete|page={{FULLPAGENAMEE}}}} سیلمک سیاهی]‌سینده باشقا بیلگیلر اولا بیلر.",
        "brokenredirectstext": "آشاغی‌داکی ایستیقامتلندیرمه‌لر مؤوجود اولمایان صحیفه‌لره کئچید وئریر:",
        "brokenredirects-edit": "دَییشدیر",
        "brokenredirects-delete": "سیل",
-       "withoutinterwiki": "دیل باغلانتیلاری اولمایان صحیفه‌لر",
+       "withoutinterwiki": "دیل باغلانتیلاری اولمایان صفحه‌لر",
        "withoutinterwiki-summary": "آشاغیداکی صفحه‌لر، آیری دیل‌لره باغلانتیلاری یوخدور.",
        "withoutinterwiki-legend": "اؤن‌اَک",
        "withoutinterwiki-submit": "گؤستر",
index 00b0696..ce5b1f9 100644 (file)
        "contributions": "{{GENDER:$1|Ҡатнашыусы}} башҡарған эш",
        "contributions-title": "$1 исемле ҡатнашыусы башҡарған эш",
        "mycontris": "Башҡарған эштәр",
-       "anoncontribs": "Ð\98Ò\93Ó\99нÓ\99ләр",
+       "anoncontribs": "Ð\91аÑ\88ҡаÑ\80Ò\93ан Ñ\8dÑ\88Ñ\82әр",
        "contribsub2": "{{GENDER:$3|$1}} башҡарған эше ($2)",
        "contributions-userdoesnotexist": "«$1» исемле иҫәп яҙыуы юҡ.",
        "nocontribs": "Күрһәтелгән шарттарға яуап биргән үҙгәртеүҙәр табылманы.",
index 2add4e2..2065f52 100644 (file)
        "nonunicodebrowser": "<strong>Папярэджаньне: ваш браўзэр не падтрымлівае Unicode-кадаваньне.</strong>\nУ выніку гэтага ўсе сымбалі ў полі рэдагаваньня, ня ўключаныя ў ASCII, будуць замененыя на іх шаснаццаткавыя коды.",
        "editingold": "<strong>Папярэджаньне: вы рэдагуеце састарэлую вэрсію гэтай старонкі.</strong>\nКалі вы паспрабуеце захаваць яе, любыя зьмены, зробленыя пасьля гэтай вэрсіі, будуць страчаныя.",
        "yourdiff": "Адрозьненьні",
-       "copyrightwarning": "Ð\9aалÑ\96 Ð»Ð°Ñ\81ка, Ð·Ñ\8cвÑ\8fÑ\80нÑ\96Ñ\86е Ñ\9eвагÑ\83 Ð½Ð° Ñ\82ое, Ñ\88Ñ\82о Ñ\9eÑ\81е Ð´Ð°Ð´Ð°Ñ\82кÑ\96 Ñ\96 Ð·Ñ\8cменÑ\8b Ñ\9e {{GRAMMAR:меÑ\81нÑ\8b|{{SITENAME}}}} Ñ\80азглÑ\8fдаÑ\8eÑ\86Ñ\86а Ñ\8fк Ð²Ñ\8bдадзенÑ\8bÑ\8f Ñ\9e Ð°Ð´Ð¿Ð°Ð²ÐµÐ´Ð½Ð°Ñ\81Ñ\8cÑ\86Ñ\96 Ð· Ñ\83мовамÑ\96 Ð»Ñ\96Ñ\86Ñ\8dнзÑ\96Ñ\96 $2 (глÑ\8fдзÑ\96Ñ\86е Ð¿Ð°Ð´Ñ\80абÑ\8fзнаÑ\81Ñ\8cÑ\86Ñ\96 Ð½Ð° $1). Ð\9aалÑ\96 Ð\92Ñ\8b Ñ\81Ñ\83пÑ\80аÑ\86Ñ\8c Ñ\82аго, ÐºÐ°Ð± Ð\92аÑ\88Ñ\8bÑ\8f Ð¼Ð°Ñ\82Ñ\8dÑ\80Ñ\8bÑ\8fлÑ\8b Ð½ÐµÐ°Ð±Ð¼ÐµÐ¶Ð°Ð²Ð°Ð½Ð° Ñ\80Ñ\8dдагавалаÑ\81Ñ\8f Ñ\96 Ñ\80аÑ\81паÑ\9eÑ\81Ñ\8eджвалаÑ\81Ñ\8f, Ð½Ðµ Ð´Ð°Ð´Ð°Ð²Ð°Ð¹Ñ\86е Ñ\96Ñ\85.<br />\nÐ\92Ñ\8b Ñ\82акÑ\81ама Ð°Ð±Ð°Ð²Ñ\8fзÑ\83еÑ\86еÑ\81Ñ\8f, Ñ\88Ñ\82о Ð\92аÑ\88 Ð¼Ð°Ñ\82Ñ\8dÑ\80Ñ\8bÑ\8fл Ð½Ð°Ð¿Ñ\96Ñ\81анÑ\8b Ð°Ñ\81абÑ\96Ñ\81Ñ\82а Ð\92амÑ\96 Ð°Ð±Ð¾ Ð·Ñ\8cÑ\8fÑ\9eлÑ\8fеÑ\86Ñ\86а Ð³Ñ\80амадзкÑ\96м Ð½Ð°Ð±Ñ\8bÑ\82кам, Ð°Ð»Ñ\8cбо Ñ\9eзÑ\8fÑ\82Ñ\8b Ð· Ð¿Ð°Ð´Ð¾Ð±Ð½Ñ\8bÑ\85 Ð²Ð¾Ð»Ñ\8cнÑ\8bÑ\85 ÐºÑ\80Ñ\8bнÑ\96Ñ\86аÑ\9e.\n'''Ð\9dÐ\95Ð\9bЬÐ\93Ð\90 Ð\91Ð\95Ð\97 Ð\94Ð\90Ð\97Ð\92Ð\9eÐ\9bУ Ð\94Ð\90Ð\94Ð\90Ð\92Ð\90ЦЬ Ð\9cÐ\90ТЭРЫЯÐ\9bЫ, Ð\90Ð\91Ð\90РÐ\9eÐ\9dÐ\95Ð\9dЫЯ Ð\90Ð\8eТÐ\90РСÐ\9aÐ\86Ð\9c Ð\9fРÐ\90Ð\92Ð\90Ð\9c!'''",
-       "copyrightwarning2": "Ð\9aалÑ\96 Ð»Ð°Ñ\81ка, Ð·Ð°Ñ\9eважÑ\86е, Ñ\88Ñ\82о Ñ\9eвеÑ\81Ñ\8c Ñ\83нÑ\91Ñ\81ак Ñ\9e {{GRAMMAR:вÑ\96навалÑ\8cнÑ\8b|{{SITENAME}}}} Ð¼Ð¾Ð¶Ð° Ñ\80Ñ\8dдагаваÑ\86Ñ\86а, Ð·Ñ\8cмÑ\8fнÑ\8fÑ\86Ñ\86а Ñ\96 Ð²Ñ\8bдалÑ\8fÑ\86Ñ\86а Ñ\96нÑ\88Ñ\8bмÑ\96 Ñ\9eдзелÑ\8cнÑ\96камÑ\96.\nÐ\9aалÑ\96 Ð\92Ñ\8b Ð· Ð³Ñ\8dÑ\82Ñ\8bм Ð½Ñ\8f Ð·Ð³Ð¾Ð´Ð½Ñ\8bÑ\8f, ÐºÐ°Ð»Ñ\96 Ð»Ð°Ñ\81ка, Ð½Ðµ Ð·Ñ\8cмÑ\8fÑ\88Ñ\87айÑ\86е Ñ\81Ñ\8eдÑ\8b Ð\92аÑ\88Ñ\8bÑ\8f Ñ\82Ñ\8dкÑ\81Ñ\82Ñ\8b.<br />\nРазÑ\8cмÑ\8fÑ\88Ñ\87Ñ\8dнÑ\8cнем Ñ\82Ñ\83Ñ\82 Ñ\82Ñ\8dкÑ\81Ñ\82аÑ\9e, Ð\92Ñ\8b Ð´Ñ\8dклÑ\8fÑ\80Ñ\83еÑ\86е, Ñ\88Ñ\82о Ð\92Ñ\8b Ð·Ñ\8cÑ\8fÑ\9eлÑ\8fеÑ\86еÑ\81Ñ\8f Ñ\96Ñ\85 Ð°Ñ\9eÑ\82аÑ\80ам, Ñ\86Ñ\96 Ð\92Ñ\8b Ñ\81капÑ\96Ñ\8fвалÑ\96 Ñ\96Ñ\85 Ð· ÐºÑ\80Ñ\8bнÑ\96Ñ\86Ñ\8b, Ñ\8fкаÑ\8f Ð´Ð°Ð·Ð²Ð°Ð»Ñ\8fе Ð²Ð¾Ð»Ñ\8cнае Ð²Ñ\8bкаÑ\80Ñ\8bÑ\81Ñ\82анÑ\8cне Ñ\81ваÑ\96Ñ\85 Ñ\82Ñ\8dкÑ\81Ñ\82аÑ\9e (дзелÑ\8f Ð¿Ð°Ð´Ñ\80абÑ\8fзнаÑ\81Ñ\8cÑ\86Ñ\8fÑ\9e Ð³Ð»Ñ\8fдзÑ\96Ñ\86е $1).\n\n'''Ð\9aÐ\90Ð\9bÐ\86 Ð\9bÐ\90СÐ\9aÐ\90, Ð\9dÐ\95 Ð\97ЬÐ\9cЯШЧÐ\90Ð\99ЦÐ\95 Ð¢Ð£Ð¢ Ð\91Ð\95Ð\97 Ð\94Ð\90Ð\97Ð\92Ð\9eÐ\9bУ Ð\9cÐ\90ТЭРЫЯÐ\9bЫ, Ð¯Ð\9aÐ\86Я Ð\90Ð¥Ð\9eÐ\8eÐ\92Ð\90ЮЦЦÐ\90 Ð\90Ð\8eТÐ\90РСÐ\9aÐ\86Ð\9c Ð\9fРÐ\90Ð\92Ð\90Ð\9c!'''",
+       "copyrightwarning": "Ð\9aалÑ\96 Ð»Ð°Ñ\81ка, Ð·Ñ\8cвÑ\8fÑ\80нÑ\96Ñ\86е Ñ\9eвагÑ\83 Ð½Ð° Ñ\82ое, Ñ\88Ñ\82о Ñ\9eÑ\81е Ð´Ð°Ð´Ð°Ñ\82кÑ\96 Ñ\96 Ð·Ñ\8cменÑ\8b Ñ\9e {{GRAMMAR:меÑ\81нÑ\8b|{{SITENAME}}}} Ñ\80азглÑ\8fдаÑ\8eÑ\86Ñ\86а Ñ\8fк Ð²Ñ\8bдадзенÑ\8bÑ\8f Ñ\9e Ð°Ð´Ð¿Ð°Ð²ÐµÐ´Ð½Ð°Ñ\81Ñ\8cÑ\86Ñ\96 Ð· Ñ\83мовамÑ\96 Ð»Ñ\96Ñ\86Ñ\8dнзÑ\96Ñ\96 $2 (глÑ\8fдзÑ\96Ñ\86е Ð¿Ð°Ð´Ñ\80абÑ\8fзнаÑ\81Ñ\8cÑ\86Ñ\96 Ð½Ð° $1). Ð\9aалÑ\96 Ð²Ñ\8b Ñ\81Ñ\83пÑ\80аÑ\86Ñ\8c Ñ\82аго, ÐºÐ°Ð± Ð²Ð°Ñ\88Ñ\8bÑ\8f Ð¼Ð°Ñ\82Ñ\8dÑ\80Ñ\8bÑ\8fлÑ\8b Ð½ÐµÐ°Ð±Ð¼ÐµÐ¶Ð°Ð²Ð°Ð½Ð° Ñ\80Ñ\8dдагавалаÑ\81Ñ\8f Ñ\96 Ñ\80аÑ\81паÑ\9eÑ\81Ñ\8eджвалаÑ\81Ñ\8f, Ð½Ðµ Ð´Ð°Ð´Ð°Ð²Ð°Ð¹Ñ\86е Ñ\96Ñ\85.<br />\nÐ\92Ñ\8b Ñ\82акÑ\81ама Ð°Ð±Ð°Ð²Ñ\8fзÑ\83еÑ\86еÑ\81Ñ\8f, Ñ\88Ñ\82о Ð²Ð°Ñ\88 Ð¼Ð°Ñ\82Ñ\8dÑ\80Ñ\8bÑ\8fл Ð½Ð°Ð¿Ñ\96Ñ\81анÑ\8b Ð°Ñ\81абÑ\96Ñ\81Ñ\82а Ð²Ð°Ð¼Ñ\96 Ð°Ð±Ð¾ Ð·Ñ\8cÑ\8fÑ\9eлÑ\8fеÑ\86Ñ\86а Ð³Ñ\80амадзкÑ\96м Ð½Ð°Ð±Ñ\8bÑ\82кам, Ð°Ð»Ñ\8cбо Ñ\9eзÑ\8fÑ\82Ñ\8b Ð· Ð¿Ð°Ð´Ð¾Ð±Ð½Ñ\8bÑ\85 Ð²Ð¾Ð»Ñ\8cнÑ\8bÑ\85 ÐºÑ\80Ñ\8bнÑ\96Ñ\86аÑ\9e.\n<strong>Ð\9dелÑ\8cга Ð±ÐµÐ· Ð´Ð°Ð·Ð²Ð¾Ð»Ñ\83 Ð´Ð°Ð´Ð°Ð²Ð°Ñ\86Ñ\8c Ð¼Ð°Ñ\82Ñ\8dÑ\80Ñ\8bÑ\8fлÑ\8b, Ð°Ð±Ð°Ñ\80оненÑ\8bÑ\8f Ð°Ñ\9eÑ\82аÑ\80Ñ\81кÑ\96м Ð¿Ñ\80авам!</strong>",
+       "copyrightwarning2": "Ð\9aалÑ\96 Ð»Ð°Ñ\81ка, Ð·Ð°Ñ\9eважÑ\86е, Ñ\88Ñ\82о Ñ\9eвеÑ\81Ñ\8c Ñ\83нÑ\91Ñ\81ак Ñ\9e {{GRAMMAR:вÑ\96навалÑ\8cнÑ\8b|{{SITENAME}}}} Ð¼Ð¾Ð¶Ð° Ñ\80Ñ\8dдагаваÑ\86Ñ\86а, Ð·Ñ\8cмÑ\8fнÑ\8fÑ\86Ñ\86а Ñ\96 Ð²Ñ\8bдалÑ\8fÑ\86Ñ\86а Ñ\96нÑ\88Ñ\8bмÑ\96 Ñ\9eдзелÑ\8cнÑ\96камÑ\96.\nÐ\9aалÑ\96 Ð²Ñ\8b Ð· Ð³Ñ\8dÑ\82Ñ\8bм Ð½Ñ\8f Ð·Ð³Ð¾Ð´Ð½Ñ\8bÑ\8f, ÐºÐ°Ð»Ñ\96 Ð»Ð°Ñ\81ка, Ð½Ðµ Ð·Ñ\8cмÑ\8fÑ\88Ñ\87айÑ\86е Ñ\81Ñ\8eдÑ\8b Ð\92аÑ\88Ñ\8bÑ\8f Ñ\82Ñ\8dкÑ\81Ñ\82Ñ\8b.<br />\nРазÑ\8cмÑ\8fÑ\88Ñ\87Ñ\8dнÑ\8cнем Ñ\82Ñ\83Ñ\82 Ñ\82Ñ\8dкÑ\81Ñ\82аÑ\9e, Ð²Ñ\8b Ð´Ñ\8dклÑ\8fÑ\80Ñ\83еÑ\86е, Ñ\88Ñ\82о Ð·Ñ\8cÑ\8fÑ\9eлÑ\8fеÑ\86еÑ\81Ñ\8f Ñ\96Ñ\85 Ð°Ñ\9eÑ\82аÑ\80ам, Ñ\86Ñ\96 Ñ\81капÑ\96Ñ\8fвалÑ\96 Ñ\96Ñ\85 Ð· ÐºÑ\80Ñ\8bнÑ\96Ñ\86Ñ\8b, Ñ\8fкаÑ\8f Ð´Ð°Ð·Ð²Ð°Ð»Ñ\8fе Ð²Ð¾Ð»Ñ\8cнае Ð²Ñ\8bкаÑ\80Ñ\8bÑ\81Ñ\82анÑ\8cне Ñ\81ваÑ\96Ñ\85 Ñ\82Ñ\8dкÑ\81Ñ\82аÑ\9e (дзелÑ\8f Ð¿Ð°Ð´Ñ\80абÑ\8fзнаÑ\81Ñ\8cÑ\86Ñ\8fÑ\9e Ð³Ð»Ñ\8fдзÑ\96Ñ\86е $1).\n\n<strong>Ð\9dе Ð·Ñ\8cмÑ\8fÑ\88Ñ\87айÑ\86е Ñ\82Ñ\83Ñ\82 Ð±ÐµÐ· Ð´Ð°Ð·Ð²Ð¾Ð»Ñ\83 Ð¼Ð°Ñ\82Ñ\8dÑ\80Ñ\8bÑ\8fлÑ\8b, Ñ\8fкÑ\96Ñ\8f Ð°Ñ\85оÑ\9eваÑ\8eÑ\86Ñ\86а Ð°Ñ\9eÑ\82аÑ\80Ñ\81кÑ\96м Ð¿Ñ\80авам!</strong>",
        "editpage-cannot-use-custom-model": "Мадэль зьместу гэтай старонкі ня можа быць зьмененая.",
-       "longpageerror": "'''Памылка: Аб’ём тэксту, які Вы спрабуеце запісаць складае $1 {{PLURAL:$1|кілябайт|кілябайты|кілябайтаў}}, што болей устаноўленага абмежаваньня на $2 {{PLURAL:$2|кілябайт|кілябайты|кілябайтаў}}.'''\nСтаронка ня можа быць захаваная.",
+       "longpageerror": "<strong>Памылка: аб’ём тэксту, які вы спрабуеце запісаць складае $1 {{PLURAL:$1|кілябайт|кілябайты|кілябайтаў}}, што болей за ўсталяванае абмежаваньне на $2 {{PLURAL:$2|кілябайт|кілябайты|кілябайтаў}}.</strong>\nСтаронка ня можа быць захаваная.",
        "readonlywarning": "<strong>Папярэджаньне: База зьвестак была заблякаваная для тэхнічнага абслугоўваньня, таму немагчыма цяпер захаваць Вашыя зьмены.</strong>\nВы можаце скапіяваць тэкст у файл на Вашым кампутары, а пазьней захаваць сюды.\n\nСыстэмны адміністратар, які заблякаваў базу зьвестак, прапанаваў наступнае тлумачэньне: $1",
        "protectedpagewarning": "'''Папярэджаньне: Гэтая старонка была абароненая, таму толькі адміністратары могуць рэдагаваць яе.'''\nАпошні запіс з журнала пададзены ніжэй для даведкі:",
        "semiprotectedpagewarning": "'''Заўвага:''' Гэтая старонка была абароненая, і рэдагаваць яе могуць толькі зарэгістраваныя ўдзельнікі.\nАпошні запіс з журнала пададзены ніжэй для даведкі:",
        "userrights-user-editname": "Увядзіце імя ўдзельніка:",
        "editusergroup": "Загрузіць групы ўдзельніка",
        "editinguser": "Зьмена правоў {{GENDER:$1|удзельніка|удзельніцы}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "Прагляд правоў {{GENDER:$1|удзельніка|удзельніцы}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Рэдагаваць групы ўдзельнікаў і ўдзельніц",
+       "userrights-viewusergroup": "Прагляд групаў удзельніка",
        "saveusergroups": "Захаваць групы {{GENDER:$1|ўдзельнікаў і ўдзельніц}}",
        "userrights-groupsmember": "Уваходзіць у:",
        "userrights-groupsmember-auto": "Няяўны чалец:",
        "action-upload_by_url": "загрузку гэтага файла з URL-адрасу",
        "action-writeapi": "выкарыстаньне API для запісаў",
        "action-delete": "выдаленьне гэтай старонкі",
-       "action-deleterevision": "вÑ\8bдаленÑ\8cне Ð³Ñ\8dÑ\82ай Ð²Ñ\8dÑ\80Ñ\81Ñ\96Ñ\96",
+       "action-deleterevision": "вÑ\8bдаленÑ\8cне Ð²Ñ\8dÑ\80Ñ\81Ñ\96Ñ\8fÑ\9e",
        "action-deletedhistory": "прагляд выдаленай гісторыі гэтай старонкі",
        "action-browsearchive": "пошук выдаленых старонак",
        "action-undelete": "аднаўленьне гэтай старонкі",
        "emailccsubject": "Копія Вашага ліста да $1: $2",
        "emailsent": "Ліст адасланы",
        "emailsenttext": "Ваш ліст быў адасланы.",
-       "emailuserfooter": "Гэты ліст быў дасланы {{GENDER:$1|ўдзельнікам|ўдзельніцай}} $1 да {{GENDER:$2|ўдзельніка|ўдзельніцы}} $2 з дапамогай функцыі «{{int:emailuser}}» {{GRAMMAR:родны|{{SITENAME}}}}.",
+       "emailuserfooter": "Гэты ліст быў дасланы {{GENDER:$1|ўдзельнікам|ўдзельніцай}} $1 да {{GENDER:$2|ўдзельніка|ўдзельніцы}} $2 з дапамогай функцыі «{{int:emailuser}}» {{GRAMMAR:родны|{{SITENAME}}}}. {{GENDER:$2|Ваш}} ліст у адказ будзе дасланы {{GENDER:$1|адпраўніку|адпраўніцы}}, і {{GENDER:$1|яму|ёй}} будзе бачны {{GENDER:$2|ваш}} адрас электроннай пошты.",
        "usermessage-summary": "Паведамленьне пра выхад з сыстэмы.",
        "usermessage-editor": "Дастаўка сыстэмных паведамленьняў",
        "watchlist": "Сьпіс назіраньня",
index e137ee9..244ac7a 100644 (file)
        "tog-numberheadings": "हेडिंग के ऑटो-नंबरिंग",
        "tog-showtoolbar": "संपादन औजारपट्टी के देखावल जाव",
        "tog-editondblclick": "दुइ क्लिक पर पन्ना सभ के संपादन करीं",
-       "tog-editsectiononrightclick": "à¤\96à¤\82ड à¤\95à¥\80 à¤¹à¥\87डिà¤\82à¤\97 à¤ªà¤° à¤¦à¤¾à¤¯à¤¾à¤\81 à¤\95à¥\8dलिà¤\95 à¤\95à¤\87 à¤\95à¥\87 à¤\96à¤\82ड à¤\95à¥\87 à¤¸à¤®à¥\8dपादित करीं",
-       "tog-watchcreations": "हमार बनावल पन्ना आ हमार अपलोड कइल फाइल सभ के हमरी धियानसूची में जोड़ दिहल जाव",
-       "tog-watchdefault": "हम जौना पन्ना आ फाइलन के संपादित करीं उनहन के हमरी धियानसूची में जोड़ दिहल जाव",
-       "tog-watchmoves": "हमरा द्वारा स्थानांतरित पन्ना आ फाइलन के हमरा धियानसूची में जोड़ दिहल जाव",
-       "tog-watchdeletion": "हमरा द्वारा हटावल पन्ना आ फाइल सभ के हमार धियानसूची में जोड़ दिहल जाव",
+       "tog-editsectiononrightclick": "हà¥\87डिà¤\82à¤\97 à¤ªà¤° à¤¦à¤¾à¤¯à¤¾à¤\81 à¤\95à¥\8dलिà¤\95 à¤\95à¤\87 à¤\95à¥\87 à¤\96à¤\82ड à¤\95à¥\87 à¤¸à¤\82पादन à¤¸à¤\82भव करीं",
+       "tog-watchcreations": "हमार बनावल पन्ना आ हमार अपलोड कइल फाइल सभ के हमरी धियानसूची में जोड़ल जाव",
+       "tog-watchdefault": "हम जौना पन्ना आ फाइलन के संपादित करीं उनहन के हमरी धियानसूची में जोड़ल जाव",
+       "tog-watchmoves": "हमरा द्वारा स्थानांतरित पन्ना आ फाइलन के हमरा धियानसूची में जोड़ल जाव",
+       "tog-watchdeletion": "हमरा द्वारा हटावल पन्ना आ फाइल सभ के हमार धियानसूची में जोड़ल जाव",
        "tog-watchuploads": "हम नया फाइल अपलोड करीं त उनहना के हमार धियानसूची में जोड़ल जाय",
-       "tog-watchrollback": "हमरा द्वारा रोलबैक कइल गइल पन्ना सभ के हमार धियानसूची में जोड़ दिहल जाव",
-       "tog-minordefault": "डिफालà¥\8dà¤\9f à¤°à¥\82प à¤¸à¥\87 à¤¸à¤\97रà¥\80 à¤¸à¤\82पादन à¤\95à¥\81ल à¤\95à¥\87 à¤\9bà¥\8bà¤\9f à¤¸à¤\82पादन à¤\95à¥\80 à¤°à¥\81प à¤®à¥\87à¤\82 à¤\9aिनà¥\8dहित à¤\95à¤\87ल à¤\9cाव",
+       "tog-watchrollback": "हमरा द्वारा रोलबैक कइल गइल पन्ना सभ के हमार धियानसूची में जोड़ल जाव",
+       "tog-minordefault": "डिफाल्ट रूप से सगरी संपादन के छोट संपादन की रुप में चिन्हित कइल जाव",
        "tog-previewontop": "झलक (प्रीव्यू) संपादन बक्सा से पहिले देखावल जाय",
        "tog-previewonfirst": "पहिला संपादन पर झलक (प्रीव्यू) देखावल जाय",
-       "tog-enotifwatchlistpages": "हमार धियानसूची में दर्ज कौनो भी पन्ना या फाइल में बदलाव होखला पर हमके ई-मेल कइल जाव",
-       "tog-enotifusertalkpages": "अगर हमरे बातचीत पन्ना पर कौनो बदलाव होखे त हमके ई-मेल कइल जाव",
-       "tog-enotifminoredits": "पन्ना आ फाइल पर छोटो बदलाव होखे त हमके ई-मेल कइल जाव",
-       "tog-enotifrevealaddr": "नोटिफिकेशन ई-मेल में हमार ई-मेल पता देखावल जाव",
-       "tog-shownumberswatching": "धियान रखे वालन सदस्यन के देखावल जाव",
+       "tog-enotifwatchlistpages": "हमार धियानसूची में दर्ज कौनो भी पन्ना या फाइल में बदलाव होखला पर हमके ईमेल कइल जाव",
+       "tog-enotifusertalkpages": "अगर हमरे बातचीत पन्ना पर कौनो बदलाव होखे त हमके ईमेल कइल जाव",
+       "tog-enotifminoredits": "पन्ना आ फाइल पर छोटो बदलाव होखे त हमके ईमेल कइल जाव",
+       "tog-enotifrevealaddr": "नोटिफिकेशन ईमेल में हमार ईमेल पता देखावल जाव",
+       "tog-shownumberswatching": "धियान à¤°à¤\96à¥\87 à¤µà¤¾à¤²à¤¨ à¤¸à¤¦à¤¸à¥\8dयन à¤\95à¥\87 à¤¸à¤\82à¤\96à¥\8dया à¤¦à¥\87à¤\96ावल à¤\9cाव",
        "tog-oldsig": "राउर वर्तमान दसखत:",
        "tog-fancysig": "दसखत के विकी पाठ के रुप में उपयोग करीं (बिना ऑटोमेटिक कड़ी के)",
        "tog-uselivepreview": "लगातार झलक (लाइव प्रीव्यू) इस्तेमाल कइल जाव",
-       "tog-forceeditsummary": "यदि à¤¸à¤\82पादन à¤¸à¤¾à¤°à¤¾à¤\82श à¤¨à¤¾ à¤¦à¤¿à¤¹ल होखे त हमके सूचित कइल जाय",
-       "tog-watchlisthideown": "हमरà¥\80 à¤§à¤¿à¤¯à¤¾à¤¨à¤¸à¥\82à¤\9aà¥\80 à¤¸à¥\87 à¤¹à¤®à¤¾à¤° à¤\96à¥\81द à¤\95à¥\87 à¤¸à¤\82पादन à¤\9bिपाà¤\88à¤\82",
+       "tog-forceeditsummary": "सà¤\82पादन à¤¸à¤\82à¤\9bà¥\87प à¤¨à¤¾ à¤­à¤°à¤² à¤\97à¤\87ल होखे त हमके सूचित कइल जाय",
+       "tog-watchlisthideown": "धियानसà¥\82à¤\9aà¥\80 à¤¸à¥\87 à¤¹à¤®à¤¾à¤° à¤\96à¥\81द à¤\95à¥\87 à¤¸à¤\82पादन à¤\9bिपावल à¤\9cाय",
        "tog-watchlisthidebots": "धियानसूची से बॉट संपादन छिपावल जाय",
        "tog-watchlisthideminor": "धियानसूची से छोट संपादन छिपावल जाय",
-       "tog-watchlisthideliu": "धियानसà¥\82à¤\9aà¥\80 à¤®à¥\87à¤\82 à¤²à¥\89à¤\97-à¤\87न à¤­à¤\87ल à¤¸à¤¦à¤¸à¥\8dयन à¤\95à¥\87 à¤¸à¤\82पादन छिपावल जाय",
+       "tog-watchlisthideliu": "à¤\96ाता à¤®à¥\87à¤\82 à¤ªà¥\8dरवà¥\87श à¤­à¤\87ल à¤ªà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता à¤²à¥\8bà¤\97 à¤\95à¥\87 à¤¸à¤\82पादन à¤§à¤¿à¤¯à¤¾à¤¨à¤¸à¥\82à¤\9aà¥\80 à¤¸à¥\87 छिपावल जाय",
        "tog-watchlistreloadautomatically": "जब कौनों फिल्टर बदलल जाय तब धियानसूची ऑटोमेटिक दोबारा लोड होखे (जावास्क्रिप्ट जरूरी)",
-       "tog-watchlisthideanons": "à¤\86à¤\87॰पà¥\80॰ à¤¸à¤¦à¤¸à¥\8dयन à¤¦à¥\8dवारा à¤\95रल à¤\97à¤\87ल à¤¸à¤®à¥\8dपादन à¤\95à¥\87 à¤¹à¤®à¤¾à¤° à¤§à¤¿à¤¯à¤¾à¤¨à¤¸à¥\82à¤\9aà¥\80 à¤®à¥\87à¤\82 से छिपावल जाय",
-       "tog-watchlisthidepatrolled": "à¤\9cाà¤\81à¤\9aल à¤\97à¤\87ल à¤¸à¤®à¥\8dपादन à¤\95à¥\87 à¤¹à¤®à¤¾à¤° à¤§à¥\8dयानसà¥\82à¤\9aà¥\80 à¤®à¥\87à¤\82 से छिपावल जाय",
+       "tog-watchlisthideanons": "बà¥\87नाम à¤ªà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता à¤²à¥\8bà¤\97 à¤\95à¥\87 à¤¸à¤\82पादन à¤§à¤¿à¤¯à¤¾à¤¨à¤¸à¥\82à¤\9aà¥\80 से छिपावल जाय",
+       "tog-watchlisthidepatrolled": "à¤\9cाà¤\81à¤\9aल à¤\97à¤\87ल à¤¸à¤\82पादन à¤\95à¥\87 à¤§à¤¿à¤¯à¤¾à¤¨à¤¸à¥\82à¤\9aà¥\80 से छिपावल जाय",
        "tog-watchlisthidecategorization": "पन्ना श्रेणीकरण छिपावल जाय",
-       "tog-ccmeonemails": "हमरा à¤¦à¥\8dवारा à¤\85नà¥\8dय à¤¸à¤¦à¤¸à¥\8dयन à¤\95à¥\87 à¤­à¥\87à¤\9cल à¤\97à¤\87ल à¤\88मà¥\87ल à¤\95à¥\87 à¤\95à¥\89पà¥\80 à¤¹à¤®à¤°à¥\8b के भेजल जाय",
+       "tog-ccmeonemails": "हमरा à¤¦à¥\8dवारा à¤\85नà¥\8dय à¤ªà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता à¤²à¥\8bà¤\97 à¤\95à¥\87 à¤­à¥\87à¤\9cल à¤\97à¤\87ल à¤\88मà¥\87ल à¤\95à¥\87 à¤\95à¥\89पà¥\80 à¤¹à¤®के भेजल जाय",
        "tog-diffonly": "अंतर देखावत समय नीचे पन्ना के सामग्री न देखावल जाय",
        "tog-showhiddencats": "छिपल श्रेणियन के भी देखावल जाय",
        "tog-norollbackdiff": "रोलबैक कइला के बाद अंतर न देखावल जाय",
        "tog-useeditwarning": "जो हम कौनों पन्ना पर संपादन करत घरी परिवर्तन के बिना सहेजले छोड़ देईं त हमके खबर कइल जाय",
-       "tog-prefershttps": "लà¥\89à¤\97िन रहले पर हमेशा सुरक्षित कनेक्शन के प्रयोग कइल जाय",
+       "tog-prefershttps": "à¤\96ाता à¤®à¥\87à¤\82 à¤ªà¥\8dरवà¥\87श रहले पर हमेशा सुरक्षित कनेक्शन के प्रयोग कइल जाय",
        "underline-always": "हमेशा",
        "underline-never": "कभी ना",
        "underline-default": "जिल्द (स्किन) या ब्राउजर डिफॉल्ट",
        "december-date": "दिसंबर $1",
        "period-am": "AM",
        "period-pm": "PM",
-       "pagecategories": "{{PLURAL:$1|श्रेणी|श्रेणी}}",
-       "category_header": "\"$1\" श्रेणी में पन्ना",
+       "pagecategories": "{{PLURAL:$1|श्रेणी|श्रेणीसभ}}",
+       "category_header": "\"$1\" à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤®à¥\8cà¤\9cà¥\82द à¤ªà¤¨à¥\8dना",
        "subcategories": "उपश्रेणी",
-       "category-media-header": "\"$1\" श्रेणी में मीडिया",
-       "category-empty": "''इ श्रेणी में इ समय कउनो पन्ना या मीडिया नइखे।''",
+       "category-media-header": "\"$1\" à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤®à¥\8cà¤\9cà¥\82द à¤®à¥\80डिया",
+       "category-empty": "<em>ए श्रेणी में एह समय कौनों पन्ना भा मीडिया नइखे।</em>",
        "hidden-categories": "{{PLURAL:$1|छिपावल गइल श्रेणी|छिपावल गइल श्रेणी सब}}",
        "hidden-category-category": "छिपावल गइल श्रेणी",
-       "category-subcat-count": "{{PLURAL:$2|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤\96ालà¥\80 à¤¨à¤¿à¤®à¥\8dनलिà¤\96ित à¤¶à¥\8dरà¥\87णà¥\80 à¤¬à¤¾|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤\95à¥\81ल $2 à¤®à¥\87à¤\82 à¤¸à¥\87 {{PLURAL:$1|à¤\89पशà¥\8dरà¥\87णà¥\80|$1 à¤\89पशà¥\8dरà¥\87णà¥\80 à¤¸à¤¬}} बा।}}",
-       "category-subcat-count-limited": "à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤¨à¤¿à¤®à¥\8dनलिà¤\96ित {{PLURAL:$1|à¤\89पशà¥\8dरà¥\87णà¥\80 à¤¬à¤¾|$1 à¤\89पशà¥\8dरà¥\87णà¥\80 बाड़ीं।}}",
-       "category-article-count": "{{PLURAL:$2|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤®à¤¾à¤¤à¥\8dर à¤¨à¤¿à¤®à¥\8dनलिà¤\96ित à¤ªà¤¨à¥\8dन à¤¬à¤¾à¥¤|à¤\87 à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤¨à¤¿à¤®à¥\8dनलिà¤\96ित {{PLURAL:$1|पनà¥\8dना à¤¬à¤¾|$1 à¤ªà¤¨à¥\8dना à¤¬à¤¾à¤¡à¤¼à¥\87}}, à¤\95à¥\81ल à¤ªà¤¨à¥\8dना $2}}",
-       "category-article-count-limited": "निमà¥\8dनलिà¤\96ित {{PLURAL:$1|पनà¥\8dना|$1 à¤ªà¤¨à¥\8dना}} à¤\87 à¤¶à¥\8dरà¥\87णà¥\80à¤\82 à¤®à¥\87à¤\82 à¤¬à¤¾।",
-       "category-file-count": "{{PLURAL:$2|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤\96ालà¥\80 à¤¨à¤¿à¤®à¥\8dनलिà¤\96ित à¤«à¤\87ल à¤¬à¤¾à¥¤|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤¨à¤¿à¤®à¥\8dनलिà¤\96ित à¤\95à¥\81ल à¤«à¤¼à¤¾à¤\87लà¤\82 $2 {{PLURAL:$1|फाà¤\87ल|$1फाà¤\87लà¤\82}} à¤¬à¤¾à¤¡à¤¼à¥\87}}",
-       "category-file-count-limited": "वरà¥\8dतमान à¤®à¥\87à¤\82 à¤¨à¤¿à¤®à¥\8dनलिà¤\96ित {{PLURAL:$1|पनà¥\8dना|$1 à¤ªà¤¨à¥\8dनाà¤\82}} à¤\87 à¤¶à¥\8dरà¥\87णà¥\80à¤\82 à¤®à¥\87à¤\82 à¤¬à¤¾à¤¡à¤¼à¥\87।",
+       "category-subcat-count": "{{PLURAL:$2|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤¨à¥\80à¤\9aà¥\87 à¤¦à¤¿à¤¹à¤² à¤\96ालà¥\80 à¤\8fà¤\95 à¤ à¥\8b à¤¶à¥\8dरà¥\87णà¥\80 à¤¬à¤¾|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤®à¥\8cà¤\9cà¥\82द à¤\95à¥\81ल $2 à¤®à¥\87à¤\82 à¤¸à¥\87 {{PLURAL:$1|à¤\89पशà¥\8dरà¥\87णà¥\80|$1 à¤\89पशà¥\8dरà¥\87णà¥\80 à¤¸à¤¬}} à¤¨à¥\80à¤\9aà¥\87 à¤¦à¥\87à¤\96ावल à¤\9cात बा।}}",
+       "category-subcat-count-limited": "à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤¨à¥\80à¤\9aà¥\87 à¤¦à¥\87à¤\96ावल {{PLURAL:$1|à¤\89पशà¥\8dरà¥\87णà¥\80 à¤¬à¤¾|$1 à¤\89पशà¥\8dरà¥\87णà¥\80 à¤\95à¥\81ल बाड़ीं।}}",
+       "category-article-count": "{{PLURAL:$2|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤¨à¥\80à¤\9aà¥\87 à¤¦à¤¿à¤¹à¤² à¤\8fà¤\95हà¥\80 à¤ à¥\8b à¤ªà¤¨à¥\8dना à¤­à¤° à¤¬à¤¾à¤\9fà¥\87।|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤®à¥\8cà¤\9cà¥\82द à¤\95à¥\81ल $2 à¤®à¥\87à¤\82 à¤¸à¥\87 {{PLURAL:$1|पनà¥\8dना à¤¨à¥\80à¤\9aà¥\87 à¤¦à¥\87à¤\96ावल à¤\9cात à¤¬à¤¾|$1 à¤ªà¤¨à¥\8dनासभ à¤¨à¥\80à¤\9aà¥\87 à¤¦à¥\87à¤\96ावल à¤\9cात à¤¬à¤¾à¤¡à¤¼à¥\87à¤\82}}।}}",
+       "category-article-count-limited": "वरà¥\8dतमान à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤¨à¥\80à¤\9aà¥\87 à¤¦à¤¿à¤¹à¤² {{PLURAL:$1|पनà¥\8dना à¤¬à¤¾|$1 à¤ªà¤¨à¥\8dना à¤¬à¤¾à¤¡à¤¼à¥\87à¤\82}}।",
+       "category-file-count": "{{PLURAL:$2|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤¨à¥\80à¤\9aà¥\87 à¤¦à¤¿à¤¹à¤² à¤\8fà¤\95हà¥\80 à¤ à¥\8b à¤«à¤¾à¤\87ल à¤­à¤° à¤¬à¤¾à¤\9fà¥\87।|à¤\8f à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤®à¥\8cà¤\9cà¥\82द à¤\95à¥\81ल $2 à¤®à¥\87à¤\82 à¤¸à¥\87 {{PLURAL:$1|फाà¤\87ल à¤¨à¥\80à¤\9aà¥\87 à¤¦à¥\87à¤\96ावल à¤\9cात à¤¬à¤¾|$1 à¤«à¤¾à¤\87लसभ à¤¨à¥\80à¤\9aà¥\87 à¤¦à¥\87à¤\96ावल à¤\9cात à¤¬à¤¾à¤¡à¤¼à¥\80à¤\82}}।}}",
+       "category-file-count-limited": "वरà¥\8dतमान à¤¶à¥\8dरà¥\87णà¥\80 à¤®à¥\87à¤\82 à¤¨à¥\80à¤\9aà¥\87 à¤¦à¤¿à¤¹à¤² {{PLURAL:$1|फाà¤\87ल à¤¬à¤¾|$1 à¤«à¤¾à¤\87ल à¤¬à¤¾à¤¡à¤¼à¥\80à¤\82}}।",
        "listingcontinuesabbrev": "जारी...",
        "index-category": "सूचीबद्ध पन्ना",
        "noindex-category": "बिनासूचीबद्ध पन्ना",
        "moredotdotdot": "अउर...",
        "morenotlisted": "हो सकेला कि ई लिस्ट पूरा न होखे।",
        "mypage": "पन्ना",
-       "mytalk": "हमार à¤¬à¤¾à¤¤à¤\9aà¥\80त à¤ªà¤¨à¥\8dना",
+       "mytalk": "बातà¤\9aà¥\80त",
        "anontalk": "बातचीत",
        "navigation": "नेविगेशन",
        "and": "&#32;अउर",
        "qbedit": "संपादन",
        "qbpageoptions": "ई पन्ना",
        "qbmyoptions": "हमार पन्ना",
-       "faq": "साधारण सवाल",
+       "faq": "à¤\86म सवाल",
        "faqpage": "Project:अक्सर पूछल जाए वाला सवाल",
-       "actions": "à¤\95ारà¥\8dयवाहà¥\80",
+       "actions": "à¤\8fà¤\95à¥\8dशन",
        "namespaces": "नाँवस्थान",
        "variants": "अउरी प्रकार",
-       "navigation-heading": "नà¥\87विà¤\97à¥\87शन à¤®à¥\87नà¥\81",
+       "navigation-heading": "नà¥\87विà¤\97à¥\87शन à¤®à¥\87नà¥\82",
        "errorpagetitle": "खराबी",
-       "returnto": "$1 à¤ªà¤° à¤²à¥\8cà¤\9f à¤\9cाà¤\88ं।",
+       "returnto": "$1 à¤ªà¤° à¤²à¤µà¤\9fà¥\80ं।",
        "tagline": "भोजपुरी {{SITENAME}} से",
        "help": "मदद",
        "search": "खोज",
        "searcharticle": "जाईं",
        "history": "पन्ना के इतिहास",
        "history_short": "इतिहास",
-       "updatedmarker": "हमार à¤\85नà¥\8dतिम à¤\86à¤\97मन à¤¸े बदलाव",
+       "updatedmarker": "हमरà¥\87 à¤\85à¤\82तिम à¤¬à¥\87र à¤¦à¥\87à¤\96लà¥\87 à¤\95à¥\87 à¤¬à¤¾à¤¦ à¤\95े बदलाव",
        "printableversion": "छापे लायक संस्करण",
        "permalink": "स्थायी कड़ी",
        "print": "छापीं",
-       "view": "दà¥\87à¤\96à¥\80à¤\82",
+       "view": "वà¥\8dयà¥\82",
        "view-foreign": "$1 पर देखीं",
        "edit": "संपादन",
        "edit-local": "लोकल विवरण देखीं",
        "create": "बनाईं",
        "create-local": "लोकल विवरण जोड़ीं",
-       "editthispage": "à¤\8f à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤¸à¤®à¥\8dपादन करीं",
-       "create-this-page": "à¤\8f à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤¨à¤¿à¤°à¥\8dमाण à¤\95रà¥\80ं",
+       "editthispage": "à¤\8f à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤¸à¤\82पादन करीं",
+       "create-this-page": "à¤\88 à¤ªà¤¨à¥\8dना à¤¬à¤¨à¤¾à¤\88ं",
        "delete": "मिटाईं",
        "deletethispage": "ई पन्ना के मिटाईं",
        "undeletethispage": "ई पन्ना के फिर से स्थापित करीं",
-       "undelete_short": "{{PLURAL:$1|à¤\8fà¤\97à¥\8b à¤¹à¤\9fावल à¤\97à¤\88ल|$1 à¤¹à¤\9fावल à¤\97à¤\88लà¤\82}} à¤¬à¤¦à¤²à¤¾à¤µ à¤µà¤¾à¤ªà¤¸ à¤²à¤¾à¤\88ं",
-       "viewdeleted_short": "देखें {{PLURAL:$1|एगो हटावल गईल सम्पादन|$1 हटावल गईल कुल सम्पादन}}",
-       "protect": "सà¤\82रà¤\95à¥\8dषण करीं",
+       "undelete_short": "{{PLURAL:$1|à¤\8fà¤\95 à¤ à¥\8b à¤¹à¤\9fावल à¤\97à¤\87ल à¤¸à¤\82पादन|$1 à¤ à¥\87 à¤¹à¤\9fावल à¤\97à¤\87ल à¤¸à¤\82पादन à¤\95à¥\81ल}} à¤¬à¤¿à¤¨à¤¾à¤®à¥\87à¤\9fावल à¤\95रà¥\80ं",
+       "viewdeleted_short": "{{PLURAL:$1|एक ठो हटावल गइल संपादन|$1 हटावल गइल संपादन कुल}} देखीं",
+       "protect": "सà¥\81रà¤\95à¥\8dषित करीं",
        "protect_change": "बदलीं",
-       "protectthispage": "à¤\87 पन्ना के सुरक्षित करीं।",
+       "protectthispage": "à¤\8f पन्ना के सुरक्षित करीं।",
        "unprotect": "सुरक्षा बदलीं",
-       "unprotectthispage": "à¤\87 पन्ना के सुरक्षा बदलीं",
+       "unprotectthispage": "à¤\8f पन्ना के सुरक्षा बदलीं",
        "newpage": "नया पन्ना",
-       "talkpage": "à¤\87 पन्ना पर चर्चा करीं",
-       "talkpagelinktext": "बात-चीत",
+       "talkpage": "à¤\8f पन्ना पर चर्चा करीं",
+       "talkpagelinktext": "बातचीत",
        "specialpage": "खास पन्ना",
-       "personaltools": "वà¥\8dयà¤\95à¥\8dतिà¤\97त औजार",
+       "personaltools": "निà¤\9cà¥\80 औजार",
        "articlepage": "सामग्री पन्ना देखीं",
-       "talk": "बात-चीत",
-       "views": "à¤\95à¤\87सन à¤²à¤\89à¤\95à¥\80?",
+       "talk": "बातचीत",
+       "views": "वà¥\8dयà¥\82",
        "toolbox": "औजार",
-       "tool-link-userrights": "{{GENDER:$1|पà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता}} à¤\95à¥\87 à¤¸à¤¦à¤¸à¥\8dयसमà¥\82ह बदलीं",
+       "tool-link-userrights": "{{GENDER:$1|पà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता}} à¤\95à¥\87 à¤®à¤\82डलà¥\80 बदलीं",
        "tool-link-emailuser": "{{GENDER:$1|प्रयोगकर्ता}} के ईमेल करीं",
        "userpage": "प्रयोगकर्ता पन्ना देखीं",
        "projectpage": "परियोजना पन्ना देखीं",
        "imagepage": "फाइल पन्ना देखीं",
-       "mediawikipage": "सनà¥\8dदà¥\87श पन्ना देखीं",
+       "mediawikipage": "सनà¥\87सा पन्ना देखीं",
        "templatepage": "टेम्पलेट पन्ना देखीं",
        "viewhelppage": "मदद पन्ना देखीं",
        "categorypage": "श्रेणी पन्ना देखीं",
-       "viewtalkpage": "बात-à¤\9aà¥\80त देखीं",
+       "viewtalkpage": "à¤\9aरà¥\8dà¤\9aा देखीं",
        "otherlanguages": "दुसरी भाषा में",
        "redirectedfrom": "($1 से अनुप्रेषित)",
        "redirectpagesub": "अनुप्रेषण पन्ना",
        "redirectto": "अनुप्रेषित:",
-       "lastmodifiedat": "$1 à¤\95à¥\87 $2 à¤ªà¤° à¤\8f à¤ªà¤¨à¥\8dना à¤ªà¤° à¤\85नà¥\8dतिम बेर बदलाव भइल।",
-       "viewcount": "à¤\88 à¤ªà¤¨à¥\8dना {{PLURAL:$1|à¤\8fà¤\95|$1}} à¤¬à¤¾à¤° à¤¦à¥\87à¤\96ल à¤\97à¤\88ल बा।",
+       "lastmodifiedat": "$1 à¤\95à¥\87 $2 à¤¬à¤\9cà¥\87 à¤\8f à¤ªà¤¨à¥\8dना à¤ªà¤° à¤\85à¤\82तिम बेर बदलाव भइल।",
+       "viewcount": "à¤\88 à¤ªà¤¨à¥\8dना {{PLURAL:$1|à¤\8fà¤\95|$1}} à¤¬à¥\87र à¤¦à¥\87à¤\96ल à¤\97à¤\87ल बा।",
        "protectedpage": "सुरक्षित पन्ना",
        "jumpto": "इहाँ जाईं:",
        "jumptonavigation": "नेविगेशन",
        "jumptosearch": "खोजीं",
-       "view-pool-error": "à¤\95à¥\8dषमा à¤\95रà¥\80à¤\82, à¤\88 à¤¸à¤®à¤¯ à¤¸à¤°à¥\8dवर à¤ªà¤° à¤¬à¤¹à¥\81त à¤\9cà¥\8dयादा à¤²à¥\8bड à¤¬à¤¢à¤¼ à¤\97à¤\88ल à¤¬à¤¾à¥¤\nà¤\88 à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤¬à¤¹à¥\81तà¥\87 à¤ªà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता à¤²à¥\8bà¤\97 à¤¦à¥\87à¤\96à¥\87 à¤\95à¥\87 à¤\95à¥\8bशिश à¤\95र à¤°à¤¹à¤² à¤¬à¤¾à¤¨à¥\80।\nà¤\88 à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤«à¤¿à¤° à¤¸à¥\87 à¤¦à¥\87à¤\96à¥\87 à¤¸à¥\87 à¤ªà¤¹à¤¿à¤²à¥\87 à¤\95à¥\83पया à¤\95à¥\81à¤\9b à¤¦à¥\87र à¤¤à¤\95 à¤\87नà¥\8dतजार करीं।\n\n$1",
-       "generic-pool-error": "à¤\95à¥\8dषमा à¤\95रà¥\80à¤\82, à¤\88 à¤¸à¤®à¤¯ à¤¸à¤°à¥\8dवर à¤ªà¤° à¤¬à¤¹à¥\81त à¤\9cà¥\8dयादा à¤²à¥\8bड à¤¬à¤¢à¤¼ à¤\97à¤\88ल à¤¬à¤¾à¥¤\nà¤\88 à¤¸à¤\82साधन à¤\95à¥\87 à¤¬à¤¹à¥\81तà¥\87 à¤ªà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता à¤²à¥\8bà¤\97 à¤¦à¥\87à¤\96à¥\87 à¤\95à¥\87 à¤\95à¥\8bशिश à¤\95र à¤°à¤¹à¤² à¤¬à¤¾à¤¨à¥\80।\nà¤\88 à¤¸à¤\82साधन à¤¤à¤\95 à¤ªà¤¹à¥\81à¤\81à¤\9a à¤¬à¤¨à¤¾à¤µà¥\87 à¤\95à¥\87 à¤\95à¥\8bशिश à¤¸à¥\87 à¤ªà¤¹à¤¿à¤²à¥\87 à¤\95à¥\83पया à¤\95à¥\81à¤\9b à¤¦à¥\87र à¤¤à¤\95 à¤\87नà¥\8dतजार करीं।",
-       "pool-timeout": "तालाबनà¥\8dदà¥\80 à¤\96ातिर à¤ªà¥\8dरतà¥\80à¤\95à¥\8dषा समय समाप्त",
+       "view-pool-error": "माफ à¤\95रà¥\80à¤\82, à¤\8f à¤¸à¤®à¤¯ à¤¸à¤°à¥\8dवर à¤ªà¤° à¤¬à¤¹à¥\81त à¤\9cà¥\8dयादा à¤²à¥\8bड à¤¬à¤¢à¤¼ à¤\97à¤\87ल à¤¬à¤¾à¥¤\nà¤\8f à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤¬à¤¹à¥\81तà¥\87 à¤ªà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता à¤²à¥\8bà¤\97 à¤¦à¥\87à¤\96à¥\87 à¤\95à¥\87 à¤\95à¥\8bशिश à¤\95र à¤°à¤¹à¤² à¤¬à¤¾à¥¤\nà¤\8f à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤«à¤¿à¤° à¤¸à¥\87 à¤¦à¥\87à¤\96à¥\87 à¤¸à¥\87 à¤ªà¤¹à¤¿à¤²à¥\87 à¤\95à¥\83पया à¤\95à¥\81à¤\9b à¤¦à¥\87र à¤¤à¤\95 à¤\87à¤\82तजार करीं।\n\n$1",
+       "generic-pool-error": "माफ à¤\95रà¥\80à¤\82, à¤\8f à¤¸à¤®à¤¯ à¤¸à¤°à¥\8dवर à¤ªà¤° à¤¬à¤¹à¥\81त à¤\9cà¥\8dयादा à¤²à¥\8bड à¤¬à¤¢à¤¼ à¤\97à¤\87ल à¤¬à¤¾à¥¤\nà¤\8f à¤¸à¤\82साधन à¤\95à¥\87 à¤¬à¤¹à¥\81तà¥\87 à¤ªà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता à¤²à¥\8bà¤\97 à¤¦à¥\87à¤\96à¥\87 à¤\95à¥\87 à¤\95à¥\8bशिश à¤\95र à¤°à¤¹à¤² à¤¬à¤¾à¥¤\nà¤\8f à¤¸à¤\82साधन à¤¤à¤\95 à¤ªà¤¹à¥\81à¤\81à¤\9a à¤¬à¤¨à¤¾à¤µà¥\87 à¤\95à¥\87 à¤\95à¥\8bशिश à¤¸à¥\87 à¤ªà¤¹à¤¿à¤²à¥\87 à¤\95à¥\83पया à¤\95à¥\81à¤\9b à¤¦à¥\87र à¤¤à¤\95 à¤\87à¤\82तजार करीं।",
+       "pool-timeout": "तालाबनà¥\8dदà¥\80 à¤\96ातिर à¤\87à¤\82तà¤\9cार समय समाप्त",
        "pool-queuefull": "पूल पंक्ति भर गइल",
-       "pool-errorunknown": "à¤\85à¤\9cà¥\8dà¤\9eात à¤¤à¥\8dरà¥\81à¤\9fि",
-       "pool-servererror": "पà¥\82ल à¤\95ाà¤\89à¤\82à¤\9fर à¤¸à¥\87वा à¤\89पलबà¥\8dध à¤¨à¤¾à¤¹à¥\80 à¤¬à¤¾ ($1)।",
-       "poolcounter-usage-error": "à¤\89पयà¥\8bà¤\97 à¤¤à¥\8dरà¥\81à¤\9fि: $1",
+       "pool-errorunknown": "नामालà¥\82म à¤\96राबà¥\80",
+       "pool-servererror": "पà¥\82ल à¤\95ाà¤\89à¤\82à¤\9fर à¤¸à¤°à¥\8dविस à¤\89पलबà¥\8dध à¤¨à¤\87à¤\96à¥\87 ($1)।",
+       "poolcounter-usage-error": "à¤\87सà¥\8dतमाल à¤\96राबà¥\80: $1",
        "aboutsite": "{{SITENAME}} के बारे में",
        "aboutpage": "Project:बारे में",
-       "copyright": "à¤\89पलबà¥\8dध à¤¸à¤¾à¤®à¤\97à¥\8dरà¥\80 $1 à¤\95à¥\87 à¤\85धà¥\80न à¤\89पलबà¥\8dध à¤¬à¤¾ à¤\9cब à¤¤à¤\95 à¤\95à¥\80 à¤\85लà¤\97 à¤¸à¥\87 à¤\89लà¥\8dलà¥\87à¤\96 à¤¨à¤¾ à¤\95रल à¤\97à¤\88ल à¤¹à¥\8bà¤\96à¥\87 ।",
+       "copyright": "à¤\89पलबà¥\8dध à¤¸à¤¾à¤®à¤\97à¥\8dरà¥\80 $1 à¤\95à¥\87 à¤\85धà¥\80न à¤\89पलबà¥\8dध à¤¬à¤¾ à¤\9cब à¤¤à¤\95 à¤\95à¥\80 à¤\85लà¤\97 à¤¸à¥\87 à¤\89लà¥\8dलà¥\87à¤\96 à¤¨à¤¾ à¤\95à¤\87ल à¤\97à¤\87ल à¤¹à¥\8bà¤\96à¥\87।",
        "copyrightpage": "{{ns:project}}:कापीराइट सब",
        "currentevents": "हाल के घटना सब",
        "currentevents-url": "Project:हाल के घटना सब",
        "portal-url": "Project:सदस्य-समाज मुख्यपन्ना",
        "privacy": "गोपनीयता नीति",
        "privacypage": "Project:गोपनीयता नीति",
-       "badaccess": "à¤\85नà¥\81मति à¤¤à¥\8dरà¥\81à¤\9fी",
-       "badaccess-group0": "रà¤\89à¤\86 à¤\9cवन à¤\95ारà¥\8dरवाà¤\88 à¤\96ातिर à¤\85नà¥\81रà¥\8bध à¤\95à¤\88लà¥\87 à¤¬à¤¾à¤¨à¥\80 à¤\89 à¤\95à¥\87 à¤¨à¤¿à¤·à¥\8dपादन à¤\95रà¥\87 à¤\95à¥\87 à¤\85नà¥\81मति à¤¨à¤\88खे।",
-       "badaccess-groups": "रà¤\89à¤\86 à¤\9cà¥\8cन à¤\95à¥\8dरिया à¤\95à¥\87 à¤¨à¤¿à¤µà¥\87दन à¤\95à¤\87लà¥\87 à¤¬à¤¾à¤¨à¥\80 à¤\89 à¤®à¤¾à¤¤à¥\8dर {{PLURAL:$2|$1 à¤¸à¤®à¥\82ह|$1 à¤¸à¤®à¥\82हà¤\82}} à¤\95à¥\87 à¤¸à¤¦à¤¸à¥\8dय à¤¹à¥\80 à¤\95र à¤¸à¤\95त à¤¬à¤¾à¤¡à¤¼à¥\87।",
+       "badaccess": "परमà¥\80शन à¤\96राबी",
+       "badaccess-group0": "à¤\9cवन à¤\95ारà¥\8dरवाà¤\88 à¤\95à¥\87 à¤®à¤¾à¤\81à¤\97 à¤\95à¤\87लà¥\87 à¤¬à¤¾à¤¨à¥\80, à¤\93à¤\95रा à¤²à¤¾à¤\97à¥\82 à¤\95रà¥\87 à¤\95à¥\87 à¤\87à¤\9cाà¤\9cत à¤°à¤\89à¤\86à¤\81 à¤\95à¥\87 à¤¨à¤\87खे।",
+       "badaccess-groups": "रà¤\89à¤\86 à¤\9cà¥\8cन à¤\95ारवाà¤\88 à¤\95à¥\87 à¤®à¤¾à¤\81à¤\97 à¤\95à¤\87लà¥\87 à¤¬à¤¾à¤¨à¥\80 à¤\8a {{PLURAL:$2|$1 à¤®à¤\82डलà¥\80|$1 à¤®à¤\82डलà¥\80 à¤¸à¤­}} à¤\95à¥\87 à¤¸à¤¦à¤¸à¥\8dय à¤²à¥\8bà¤\97 à¤­à¤° à¤\95र à¤¸à¤\95त à¤¬à¤¾।",
        "versionrequired": "मिडीयाविकी के संस्करण $1 के होखल जरुरी बा",
-       "versionrequiredtext": "à¤\87 à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤ªà¥\8dरयà¥\8bà¤\97 à¤\95रà¥\87 à¤\96ातिर à¤®à¥\80डियाविà¤\95à¥\80 à¤\95à¥\87 $1 à¤¸à¤\82सà¥\8dà¤\95रण à¤\9c़रà¥\82रà¥\80 à¤¬à¤¾à¥¤\nदà¥\87à¤\96à¥\80à¤\82 [[Special:Version|सà¤\82सà¥\8dà¤\95रण à¤ªà¤¨à¥\8dना]]।",
-       "ok": "ठिक",
+       "versionrequiredtext": "à¤\8f à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤ªà¥\8dरयà¥\8bà¤\97 à¤\95रà¥\87 à¤\96ातिर à¤®à¥\80डियाविà¤\95à¥\80 à¤\95à¥\87 à¤µà¤°à¥\8dशन $1 à¤\9cरà¥\82रà¥\80 à¤¬à¤¾à¥¤\n[[Special:Version|वरà¥\8dशन à¤ªà¤¨à¥\8dना]] à¤¦à¥\87à¤\96à¥\80à¤\82।",
+       "ok": "ठà¥\80क",
        "retrievedfrom": "\"$1\" से लिहल गइल",
        "youhavenewmessages": "रउआ लगे बा $1 ($2).",
-       "youhavenewmessagesfromusers": "रउआ खातिर {{PLURAL:$3|एगो अन्य सदस्य|$3 अन्य सदस्यन}} के $1 बा। ($2)",
-       "youhavenewmessagesmanyusers": "रà¤\89à¤\86 à¤\96ातिर à¤\95à¤\88 à¤¸à¤¦à¤¸à¥\8dयन à¤¦à¥\8dवारा $1 à¤¬à¤¾à¥¤ ($2)",
-       "newmessageslinkplural": "{{PLURAL:$1|à¤\8fà¤\95 à¤¨à¤¯à¤¾ à¤¸à¤¨à¥\8dदà¥\87श|999=नयà¤\95ा à¤¸à¤¨à¥\8dदà¥\87श}}",
-       "newmessagesdifflinkplural": "पिछला {{PLURAL:$1|बदलाव|999=बदलाव}}",
-       "youhavenewmessagesmulti": "रà¤\89à¤\86 à¤²à¤\97à¥\87 $1 à¤ªà¤° à¤¨à¤¯à¤¾ à¤¸à¤¨à¥\8dदà¥\87श बा",
+       "youhavenewmessagesfromusers": "{{PLURAL:$4|रउवाँ खातिर}}{{PLURAL:$3|अउरी प्रयोगकर्ता के|$3 प्रयोगकर्ता लोग}} के $1 बा ($2)।",
+       "youhavenewmessagesmanyusers": "रà¤\89वाà¤\81 à¤\96ातिर à¤\95à¤\88 à¤ªà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता à¤²à¥\8bà¤\97 à¤\95à¥\87 à¤­à¥\87à¤\9cल $1 à¤¬à¤¾ ($2)।",
+       "newmessageslinkplural": "{{PLURAL:$1|नया à¤¸à¤¨à¥\87सा|999=नया à¤¸à¤¨à¥\87सा à¤¸à¤­}}",
+       "newmessagesdifflinkplural": "पिछला {{PLURAL:$1|बदलाव|999=बदलाव}}",
+       "youhavenewmessagesmulti": "राà¤\89वाà¤\81 à¤\96ातिर $1 à¤ªà¤° à¤¨à¤¯à¤¾ à¤¸à¤¨à¥\87सा बा",
        "editsection": "संपादन",
        "editold": "संपादन",
        "viewsourceold": "स्रोत देखीं",
        "editlink": "संपादन",
        "viewsourcelink": "स्रोत देखीं",
-       "editsectionhint": "सà¤\82पादन à¤\96à¤\82ड: $1",
-       "toc": "सामà¤\97à¥\8dरी",
-       "showtoc": "दà¥\87à¤\96ाà¤\88ं",
-       "hidetoc": "à¤\9bà¥\81पाईं",
+       "editsectionhint": "à¤\96à¤\82ड à¤\95à¥\87 à¤¸à¤\82पादन: $1",
+       "toc": "बिसयसà¥\82à¤\9aी",
+       "showtoc": "दà¥\87à¤\96à¥\80ं",
+       "hidetoc": "à¤\9bिपाईं",
        "collapsible-collapse": "सेकुड़ीं",
-       "collapsible-expand": "फà¥\88लाईं",
+       "collapsible-expand": "फà¤\87लाईं",
        "confirmable-confirm": "का {{GENDER:$1|आप}} निश्चित बानी?",
        "confirmable-yes": "जी",
        "confirmable-no": "ना",
-       "thisisdeleted": "दà¥\87à¤\96à¥\80à¤\82 à¤¯à¤¾ à¤­à¤\82डार करीं $1?",
-       "viewdeleted": "$1 à¤¦à¥\87à¤\96ब?",
-       "restorelink": "देखीं {{PLURAL:$1|एगो हटावल गईल सम्पादन|$1 हटावल गईल कुल सम्पादन}}",
-       "feedlinks": "फ़à¥\80ड:",
-       "feed-invalid": "à¤\97लत à¤¸à¤¬à¥\8dसà¥\8dà¤\95à¥\8dरà¥\80पà¥\8dशन à¤«à¤¼ीड प्रकार",
-       "feed-unavailable": "सà¤\82à¤\98 à¤«à¤¼à¥\80ड à¤\89पलबà¥\8dध à¤¨à¤\87à¤\96à¥\87",
-       "site-rss-feed": "$1 आर एस एस फिड",
+       "thisisdeleted": "दà¥\87à¤\96à¥\80à¤\82 à¤¯à¤¾ à¤°à¤¿à¤¸à¥\8dà¤\9fà¥\8bर करीं $1?",
+       "viewdeleted": "$1 à¤¦à¥\87à¤\96ावल à¤\9cाय?",
+       "restorelink": "{{PLURAL:$1|एक ठो हटावल संपादन|$1 ठे हटावल संपादन}}",
+       "feedlinks": "फीड:",
+       "feed-invalid": "à¤\85वà¥\88ध à¤¸à¤¬à¤¸à¥\8dà¤\95à¥\8dरिपà¥\8dशन à¤«ीड प्रकार",
+       "feed-unavailable": "सिà¤\82डिà¤\95à¥\87शन à¤«à¥\80ड à¤\89पलबà¥\8dध à¤¨à¤\87à¤\96à¥\87à¤\82",
+       "site-rss-feed": "$1 आरएसएस फीड",
        "site-atom-feed": "$1 एटम फीड",
-       "page-rss-feed": "\"$1\" आर एस एस फिड",
+       "page-rss-feed": "\"$1\" आरएसएस फिड",
        "page-atom-feed": "\"$1\" एटम फीड",
        "red-link-title": "$1 (पन्ना मौजूद नइखे)।",
        "sort-descending": "उतरत क्रम में",
        "sort-ascending": "चढ़त क्रम में",
        "nstab-main": "पन्ना",
-       "nstab-user": "सदसà¥\8dय पन्ना",
+       "nstab-user": "पà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता पन्ना",
        "nstab-media": "मीडिया पन्ना",
        "nstab-special": "विशेष पन्ना",
        "nstab-project": "प्रोजेक्ट पन्ना",
        "nstab-image": "फाइल",
-       "nstab-mediawiki": "सनà¥\8dदà¥\87श",
+       "nstab-mediawiki": "सनà¥\87सा",
        "nstab-template": "टेम्पलेट",
        "nstab-help": "मदद पन्ना",
        "nstab-category": "श्रेणी",
        "mainpage-nstab": "मुख्य पन्ना",
-       "nosuchaction": "à¤\85à¤\88सन à¤\95à¥\8cनà¥\8b à¤\95ारà¥\8dरवाà¤\88 à¤¨à¤¾à¤¹à¤¿",
-       "nosuchactiontext": "à¤\87 à¤¯à¥\82॰à¤\86र॰à¤\8fल à¤¦à¥\8dवारा à¤¨à¤¿à¤°à¥\8dदिषà¥\8dà¤\9f à¤\95à¥\8dरिया à¤\85वà¥\88ध à¤¬à¤¾à¥¤\nरà¤\89à¤\86 à¤¯à¥\82॰à¤\86र॰à¤\8fल à¤\97लत à¤²à¤¿à¤\96लà¥\87 à¤¹à¥\8bà¤\96ब, à¤¯à¤¾ à¤\95à¤\89नà¥\8b à¤\97लत à¤\95ड़à¥\80 à¤\95à¥\87 à¤ªà¥\8dरयà¥\8bà¤\97 à¤\95à¤\87लà¥\87 à¤¹à¥\8bà¤\96ब।\nà¤\87 {{SITENAME}} à¤\95à¥\87 à¤¸à¥\89फ़à¥\8dà¤\9fवà¥\87यर à¤®à¥\87à¤\82 à¤¤à¥\8dरà¥\81à¤\9fि भी हो सकत बा।",
-       "nosuchspecialpage": "à¤\85à¤\88सन à¤\95à¥\8cनà¥\8b à¤\96़ाश à¤ªà¤¨à¥\8dना à¤¨à¤¾à¤¹à¤¿",
-       "nospecialpagetext": "<strong>रउआ एगो अवैद्य विशेष पन्ना के अनुरोध कईले बानी।</strong>\n\nवैद्य विशेष पन्ना के सूची मिल सकत बा [[Special:SpecialPages|{{int:specialpages}}]] पर।",
-       "error": "तà¥\8dरà¥\81à¤\9fी",
-       "databaseerror": "डà¥\87à¤\9fाबà¥\87स à¤¤à¥\8dरà¥\81à¤\9fी",
-       "databaseerror-text": "डाà¤\9fाबà¥\87स à¤\85नà¥\81रà¥\8bध à¤¤à¥\8dरà¥\81à¤\9fि  à¤­à¤\87ल à¤¬à¤¾à¥¤\nसà¤\82भवतà¤\83 à¤¸à¥\89फ़्टवेयर में गड़बड़ी बा।",
-       "databaseerror-textcl": "डाà¤\9fाबà¥\87स à¤\85नà¥\81रà¥\8bध à¤¤à¥\8dरà¥\81à¤\9fि à¤\89तà¥\8dतà¥\8dपनà¥\8dन à¤¹à¥\8b à¤\97à¤\88ल बा।",
+       "nosuchaction": "à¤\85à¤\87सन à¤\95à¥\8cनà¥\8b à¤\95ारà¥\8dरवाà¤\88 à¤¨à¤\87à¤\96à¥\87",
+       "nosuchactiontext": "à¤\8f à¤¯à¥\82॰à¤\86र॰à¤\8fल à¤¦à¥\8dवारा à¤¬à¤¤à¤¾à¤µà¤² à¤\95ारà¥\8dरवाà¤\88 à¤\85वà¥\88ध à¤¬à¤¾à¥¤\nरà¤\89वाà¤\81 à¤¯à¥\82॰à¤\86र॰à¤\8fल à¤\97लत à¤²à¤¿à¤\96लà¥\87 à¤¹à¥\8bà¤\96ब, à¤¯à¤¾ à¤\95वà¥\8dनà¥\8b à¤\97लत à¤\95ड़à¥\80 à¤\95à¥\87 à¤\87सà¥\8dतà¥\87माल à¤\95à¤\87लà¥\87 à¤¹à¥\8bà¤\96ब।\n{{SITENAME}} à¤®à¥\87à¤\82 à¤\87सà¥\8dतमाल à¤¹à¥\8b à¤°à¤¹à¤² à¤¸à¥\89फà¥\8dà¤\9fवà¥\87यर à¤®à¥\87à¤\82 à¤\96राबà¥\80 à¤\95à¥\87 à¤²à¤\9aà¥\8dà¤\9bन भी हो सकत बा।",
+       "nosuchspecialpage": "à¤\85à¤\87सन à¤\95à¥\8cनà¥\8b à¤\96ास à¤ªà¤¨à¥\8dना à¤¨à¤\87à¤\96à¥\87",
+       "nospecialpagetext": "<strong>रउआँ एगो अवैध खास पन्ना के अनुरोध कइले बानी।</strong>\n\nबैध खास पन्नासभ के लिस्ट [[Special:SpecialPages|{{int:specialpages}}]] पर देखल जा सकत बा।",
+       "error": "à¤\96राबी",
+       "databaseerror": "डà¥\87à¤\9fाबà¥\87स à¤\96राबी",
+       "databaseerror-text": "à¤\95à¥\8cनà¥\8bà¤\82 à¤¡à¤¾à¤\9fाबà¥\87स à¤\95à¥\8dवà¥\88रà¥\80 à¤\96राबà¥\80 à¤­à¤\87ल à¤¬à¤¾à¥¤\nसà¤\82भवतà¤\83 à¤¸à¥\89फ्टवेयर में गड़बड़ी बा।",
+       "databaseerror-textcl": "à¤\95à¥\8cनà¥\8bà¤\82 à¤¡à¤¾à¤\9fाबà¥\87स à¤\85नà¥\81रà¥\8bध à¤\96राबà¥\80 à¤\89तà¥\8dतà¥\8dपनà¥\8dन à¤¹à¥\8b à¤\97à¤\87ल बा।",
        "databaseerror-query": "अनुरोध: $1",
-       "databaseerror-function": "फ़à¤\82à¤\95à¥\8dशन: $1",
-       "databaseerror-error": "तà¥\8dरà¥\81à¤\9fि: $1",
-       "transaction-duration-limit-exceeded": "हाई रिप्लिकेशन लैग बनावे से बचे खातिर ई ट्रांजेक्शन निरस्त कर दिहल गइल, काहें से की राइट करे में लागे वाला समय ($1), $2 के सीमा से अधिक रहल।\nअगर आ कई ठो आइटम एकही साथ बदलत होखीं, तब कई टुकड़ा में ई काम करे के कोसिस करीं।",
-       "laggedslavemode": "'''चेतावनी:''' इ पन्ना पर हाल के बदलाव ना होखे के आशंका बा।",
-       "readonly": "डà¥\87à¤\9fाबà¥\87स à¤²à¥\89à¤\95 बा",
-       "enterlockreason": "लà¥\89à¤\95 à¤\95रà¥\87 à¤\95à¥\87 à¤\95ारण à¤¦à¤¿à¤¹à¥\80à¤\82, à¤¸à¤¾à¤¥à¥\87 à¤²à¥\89à¤\95 à¤\96à¥\81लà¥\87 à¤\95à¥\87 à¤¸à¤®à¤¯ à¤\95à¥\87 à¤²à¤\97भà¤\97 à¤\86à¤\95लन à¤¦à¤¿à¤¹à¥\80à¤\82।",
-       "readonlytext": "डाà¤\9fाबà¥\87स à¤¨à¤¯à¤¾ à¤¸à¤\82पादन à¤\86 à¤\85नà¥\8dय à¤¬à¤¦à¤²à¤¾à¤µ à¤\96ातिर à¤²à¥\89à¤\95 à¤\95रल à¤\97à¤\87ल à¤¬à¤¾, à¤¶à¤¾à¤¯à¤¦ à¤°à¥\81à¤\9fà¥\80न à¤®à¥\87à¤\82à¤\9fà¥\87ननà¥\8dस à¤\95à¥\87 à¤\9aलतà¥\87, à¤\9cà¥\87à¤\95रा à¤¬à¤¾à¤¦ à¤\8f à¤\95à¥\87 à¤¸à¤¾à¤®à¤¾à¤¨à¥\8dय à¤¸à¥\8dथितà¥\80 à¤®à¥\87à¤\82 à¤\86 à¤\9cायà¥\87 à¤\95à¥\87 à¤\9aाहà¥\80à¤\82।\n\nà¤\9cà¤\89न à¤¸à¤¿à¤¸à¥\8dà¤\9fम à¤ªà¥\8dरबà¤\82धà¤\95 à¤\8fह à¤\95à¥\87 à¤²à¥\89à¤\95 à¤\95à¤\87लà¥\87 à¤°à¤¹à¤²à¤¨ à¤\95ारण à¤¦à¥\87हलà¥\87 à¤¬à¤¾à¤¡à¤¼à¤¨ à¤\95ि: $1",
-       "missing-article": "डà¥\87à¤\9fाबास à¤\8a à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤ªà¤¾à¤ à¥\8dय à¤\95à¥\87 à¤¨à¤¾ à¤\96à¥\8bà¤\9c à¤ªà¤¾à¤\88ल à¤\9cà¥\8cन à¤\88 à¤\95à¥\87 à¤\96à¥\8bà¤\9cà¥\87 à¤\95à¥\87 à¤°à¤¹à¤², à¤¨à¤¾à¤®à¤¿à¤¤ \"$1\" $2.\nà¤\88 à¤¸à¤¬ à¤¸à¤¾à¤§à¤¾à¤°à¤£à¤¤: à¤¨à¤¿à¤®à¥\8dनलिà¤\96à¥\80त à¤\85पà¥\8dरà¤\9aलित à¤\85नà¥\8dतर à¤\85थवा à¤\8fà¤\97à¥\8b à¤ªà¤¨à¥\8dना à¤ªà¤° à¤\87तिहास à¤\95à¥\87 à¤²à¤¿à¤\82à¤\95 à¤\9cà¥\8cन à¤®à¤¿à¤\9fा à¤¦à¤¿à¤¹à¤² à¤\97à¤\88ल à¤¬à¤¾ à¤\95à¥\87 à¤\95ारण à¤­à¤\88ल।\n\nयदि à¤\88 à¤¬à¤¾à¤¤ à¤¨à¤\88à¤\96à¥\87, à¤¤ à¤¹à¥\8b à¤¸à¤\95त à¤¬à¤¾ à¤¸à¥\89फà¥\8dà¤\9fवà¥\87यर à¤®à¥\87à¤\82 à¤¬à¤\97 à¤ªà¤¾à¤µà¤¤ à¤¹à¥\8bà¤\96ब।\nà¤\95à¥\83पया à¤\88 à¤\8fà¤\97à¥\8b  [[Special:ListUsers/sysop|पà¥\8dरबनà¥\8dधà¤\95]] à¤\95à¥\87 à¤¯à¥\82 à¤\86र à¤\8fल à¤\95à¥\87 à¤¬à¤¾à¤°à¥\87 à¤®à¥\87à¤\82 à¤\8fà¤\97à¥\8b à¤¨à¥\8bà¤\9f à¤¬à¤¨à¤¾के खबर करीं।",
-       "missingarticle-rev": "(सà¤\82शà¥\8bधन#: $1)",
+       "databaseerror-function": "फंक्शन: $1",
+       "databaseerror-error": "à¤\96राबà¥\80: $1",
+       "transaction-duration-limit-exceeded": "हाई रिप्लिकेशन लैग बनावे से बचे खातिर ई ट्रांजेक्शन निरस्त कर दिहल गइल, काहें से की राइट करे में लागे वाला समय ($1), $2 के सीमा से अधिक रहल ह।\nअगर आप कई ठो आइटम एकही साथ बदलत होखीं, तब कई टुकड़ा में ई काम करे के कोसिस करीं।",
+       "laggedslavemode": "<strong>चेतावनी:</strong> अइसन भी हो सकेला कि पन्ना पर हाल के अपडेट न होखे।",
+       "readonly": "डà¥\87à¤\9fाबà¥\87स à¤¤à¤¾à¤²à¤¾à¤¬à¤\82दà¥\80 बा",
+       "enterlockreason": "तालाबà¤\82दà¥\80 à¤\95à¥\87 à¤\95ारण à¤¦à¥\80à¤\82, à¤\86 à¤\85नà¥\81मान à¤¬à¤¤à¤¾à¤\88à¤\82 à¤\95ि à¤\95ब à¤¤à¤¾à¤²à¤¾à¤¬à¤\82दà¥\80 à¤¹à¤\9fà¥\80",
+       "readonlytext": "नया à¤¸à¤\82पादन à¤\86 à¤\85नà¥\8dय à¤¬à¤¦à¤²à¤¾à¤µ à¤\96ातिर à¤¡à¤¾à¤\9fाबà¥\87स à¤ªà¤° à¤¤à¤¾à¤²à¤¾à¤¬à¤\82दà¥\80 à¤¬à¤¾, à¤¶à¤¾à¤¯à¤¦ à¤°à¥\81à¤\9fà¥\80न à¤®à¥\87à¤\82à¤\9fà¥\87ननà¥\8dस à¤\95à¥\87 à¤\9aलतà¥\87, à¤\9cà¥\87à¤\95रा à¤¬à¤¾à¤¦ à¤\8f à¤\95à¥\87 à¤¸à¤¾à¤®à¤¾à¤¨à¥\8dय à¤¸à¥\8dथितà¥\80 à¤®à¥\87à¤\82 à¤\86 à¤\9cायà¥\87 à¤\95à¥\87 à¤\9aाहà¥\80à¤\82।\n\nतालाबà¤\82दà¥\80 à¤\95रà¥\87 à¤µà¤¾à¤²à¤¾ à¤¸à¤¿à¤¸à¥\8dà¤\9fम à¤ªà¥\8dरबà¤\82धà¤\95 à¤\95à¥\87 à¤¬à¤¤à¤¾à¤µà¤² à¤\95ारण: $1",
+       "missing-article": "डà¥\87à¤\9fाबास à¤\95à¥\87 à¤\93 à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤ªà¤¾à¤  à¤¨à¤¾ à¤®à¤¿à¤²à¤² à¤\9cवन à¤®à¤¿à¤²à¥\87 à¤\95à¥\87 à¤\9aाहत à¤°à¤¹à¤², à¤\8fà¤\95र à¤¨à¤¾à¤\81व à¤°à¤¹à¤² \"$1\" $2।\nà¤\86मतà¥\8cर à¤ªà¤° à¤\85à¤\87सन à¤¤à¤¬ à¤¹à¥\8bला à¤ªà¥\81रान à¤¹à¥\8b à¤\9aà¥\81à¤\95ल à¤\85à¤\82तर à¤¯à¤¾ à¤¹à¤\9fावल à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤\87तिहास à¤\95à¥\87 à¤\95ड़à¥\80 à¤\95à¥\87 à¤ªà¥\80à¤\9bा à¤\95à¤\87ल à¤\9cा à¤°à¤¹à¤² à¤¹à¥\8bà¤\96à¥\87।\n\nयदि à¤\88 à¤¬à¤¾à¤¤ à¤¨à¤\87à¤\96à¥\87, à¤¤à¤¬ à¤¹à¥\8b à¤¸à¤\95à¥\87ला à¤\86पà¤\95à¥\87 à¤\95à¥\8cनà¥\8bà¤\82 à¤¸à¥\89फà¥\8dà¤\9fवà¥\87यर à¤¬à¤\97 à¤®à¤¿à¤² à¤\97à¤\87ल à¤¹à¥\8bà¤\96à¥\87।\n[[Special:ListUsers/sysop|पà¥\8dरबà¤\82धà¤\95]] à¤\95à¥\87 à¤\88 à¤¯à¥\82à¤\86रà¤\8fल à¤¦à¥\87 के खबर करीं।",
+       "missingarticle-rev": "(बदलाव#: $1)",
        "missingarticle-diff": "(अंतर: $1, $2)",
-       "readonly_lag": "à¤\89पमà¥\81à¤\96à¥\8dय à¤¡à¤¾à¤\9fाबà¥\87स à¤¸à¤°à¥\8dवर à¤®à¥\81à¤\96à¥\8dय à¤¡à¤¾à¤\9fाबà¥\87स à¤\95à¥\87 à¤¬à¤°à¤¾à¤¬à¤° à¤ªà¤°à¤¾à¤µà¤°à¥\8dतित à¤¹à¥\8bत à¤¸à¤®à¤¯ à¤®à¥\81à¤\96à¥\8dय à¤¡à¤¾à¤\9fाबà¥\87स à¤¸à¤°à¥\8dवर अपने आप लॉक हो गइल।",
+       "readonly_lag": "निà¤\9aला à¤¡à¤¾à¤\9fाबà¥\87स à¤¸à¤°à¥\8dवर à¤\9cबलà¥\87 à¤®à¥\81à¤\96à¥\8dय à¤¡à¤¾à¤\9fाबà¥\87स à¤¸à¤°à¥\8dवर à¤\95à¥\87 à¤\97ति à¤ªà¤\95ड़ à¤ªà¤¾à¤µà¥\87, à¤¡à¤¾à¤\9fाबà¥\87स अपने आप लॉक हो गइल।",
        "nonwrite-api-promise-error": "'Promise-Non-Write-API-Action' ऍचटीटीपी हेडर भेजल गइल रहल बाकी ई रिक्वेस्ट एपीआइ राइट मॉड्यूल खातिर रहल।",
-       "internalerror": "à¤\86नà¥\8dतरिà¤\95 à¤¤à¥\8dरà¥\81à¤\9fि",
-       "internalerror_info": "à¤\86नà¥\8dतरिà¤\95 à¤¤à¥\8dरà¥\81à¤\9fि: $1",
-       "internalerror-fatal-exception": "प्रकार के गंभीर अपवाद \"$1\"",
-       "filecopyerror": "\"$1\" फ़ाइल के \"$2\" पर प्रतिलिपि ना बन पाईल।",
-       "filerenameerror": "\"$1\" फ़ाइल के नाम बदल के \"$2\" नइखे रखल जा सकत।",
-       "filedeleteerror": "\"$1\" फ़ाइल के ना हटावल जा सकल।",
+       "internalerror": "à¤\85à¤\82दरà¥\82नà¥\80 à¤\96राबà¥\80",
+       "internalerror_info": "à¤\85à¤\82दरà¥\82नà¥\80 à¤\96राबà¥\80: $1",
+       "internalerror-fatal-exception": "\"$1\" प्रकार के घातक अपवाद",
+       "filecopyerror": "फाइल \"$1\" के \"$2\" पर नकल ना बन पावल।",
+       "filerenameerror": "फाइल \"$1\" के नाँव बदल के \"$2\" नइखे रखल जा सकत।",
+       "filedeleteerror": "फाइल \"$1\" के हटावल ना जा सकल।",
        "directorycreateerror": "\"$1\" डाइरेक्टरी ना बनावल जा सकल।",
-       "directoryreadonlyerror": "निरà¥\8dदà¥\87शिà¤\95ा \"$1\" à¤¸à¤¿à¤°à¥\8dफ à¤ªà¤ à¤¨à¥\80य बा।",
-       "directorynotreadableerror": "निरà¥\8dदà¥\87शिà¤\95ा \"$1\" à¤ªà¤ à¤¨à¥\80य नइखे।",
-       "filenotfound": "\"$1\" फ़ाइल ना मिलल।",
-       "unexpected": "à¤\85नपà¥\87à¤\95à¥\8dषित à¤®à¥\82लà¥\8dय: \"$1\"=\"$2\".",
-       "formerror": "तà¥\8dरà¥\81à¤\9fि: à¤«à¤¼à¥\89रà¥\8dम à¤¸à¤¬à¤®à¤¿à¤\9f à¤¨à¤¾ à¤\95रल जा सकल।",
-       "badarticleerror": "à¤\87 à¤ªà¤¨à¥\8dना à¤ªà¤° à¤\87 à¤\95ारà¥\8dय à¤¨à¤\87à¤\96à¥\87 à¤\95रल à¤\9cा à¤¸à¤\95त।",
-       "cannotdelete": "\"$1\" à¤ªà¤¨à¥\8dना à¤¯à¤¾ à¤«à¤¾à¤\87ल à¤\95à¥\87 à¤¹à¤\9fावल à¤¨à¤\87à¤\96à¥\87 à¤\9cा à¤¸à¤\95त।\nशायद à¤\95à¥\87हà¥\81 à¤\85à¤\89र à¤\87 à¤\95à¥\87 à¤ªà¤¹à¤¿à¤²à¥\87 à¤¹à¤¿ हटा चुकल होखे।",
+       "directoryreadonlyerror": "डाà¤\87रà¥\87à¤\95à¥\8dà¤\9fरà¥\80 \"$1\" à¤\96ालà¥\80 à¤ªà¤¢à¤¼à¥\87 à¤\96ातिर बा।",
+       "directorynotreadableerror": "डाà¤\87रà¥\87à¤\95à¥\8dà¤\9fरà¥\80 \"$1\" à¤ªà¤¢à¤¼à¥\87 à¤²à¤¾à¤¯à¤\95 नइखे।",
+       "filenotfound": "फाइल \"$1\" ना मिलल।",
+       "unexpected": "à¤\89मà¥\87द à¤¸à¥\87 à¤¹à¤\9f à¤\95à¥\87 à¤µà¥\88लà¥\8dयà¥\82: \"$1\"=\"$2\".",
+       "formerror": "à¤\96राबà¥\80: à¤«à¤¾à¤°à¥\8dम à¤\9cमा à¤¨à¤¾ à¤\95à¤\87ल जा सकल।",
+       "badarticleerror": "à¤\8f à¤ªà¤¨à¥\8dना à¤ªà¤° à¤\88 à¤\95ाम à¤¨à¤¾ à¤¹à¥\8b à¤¸à¤\95à¥\80।",
+       "cannotdelete": "\"$1\" à¤¨à¤¾à¤\81व à¤\95à¥\87 à¤ªà¤¨à¥\8dना à¤¯à¤¾ à¤«à¤¾à¤\87ल à¤\95à¥\87 à¤¨à¤¾ à¤¹à¤\9fावल à¤\9cा à¤¸à¤\95त à¤¬à¤¾à¥¤\nहà¥\8b à¤¸à¤\95à¥\87ला à¤\95à¥\87हà¥\82 à¤ªà¤¹à¤¿à¤²à¤¹à¥\80à¤\82 à¤\8fà¤\95रा à¤\95à¥\87 हटा चुकल होखे।",
        "cannotdelete-title": "\"$1\" पन्ना के हटावल नइखे जा सकत",
-       "delete-hook-aborted": "हà¥\81à¤\95 à¤¦à¥\8dवारा à¤¹à¤\9fायà¥\87à¤\95à¥\87 à¤\95à¥\8dरिया à¤¬à¥\80à¤\9aà¥\87 à¤®à¥\87à¤\82 à¤\9bà¥\8bड़ल à¤\97à¤\88ल।\nà¤\87 à¤\95à¤\89नà¥\8b à¤\95ारण à¤¨à¤\88à¤\96à¥\87 बतवले।",
-       "no-null-revision": "पनà¥\8dना \"$1\" à¤\96ातिर à¤¨à¤¯à¤¾ à¤\85शà¤\95à¥\8dत à¤¸à¤\82शोधन ना बन सकल",
+       "delete-hook-aborted": "हà¥\81à¤\95 à¤¦à¥\8dवारा à¤¹à¤\9fावà¥\87 à¤\95à¥\87 à¤\95ारà¥\8dरवाà¤\88 à¤¬à¥\80à¤\9aà¥\87 à¤®à¥\87à¤\82 à¤\9bà¥\8bड़ल à¤\97à¤\87ल।\nबिना à¤\95à¥\8cनà¥\8bà¤\82 à¤\95ारण बतवले।",
+       "no-null-revision": "पनà¥\8dना \"$1\" à¤\96ातिर à¤¨à¤¯à¤¾ à¤\96ालà¥\80 à¤¸à¤\82सोधन ना बन सकल",
        "badtitle": "खराब टाइटिल",
-       "badtitletext": "रà¤\89à¤\86 à¤¦à¥\8dवारा à¤\85नà¥\81रà¥\8bधित à¤¶à¥\80रà¥\8dषà¤\95 à¤\85यà¥\8bà¤\97à¥\8dय, à¤\96़ालà¥\80 à¤¯à¤¾ à¤\97लत à¤\9cà¥\81ड़ल à¤\85à¤\82तर-भाषà¥\80य à¤¯à¤¾ à¤\85à¤\82तर-विà¤\95ि à¤¶à¥\80रà¥\8dषà¤\95 à¤¬à¤¾à¥¤\nà¤\8f à¤®à¥\87à¤\82 à¤\8fà¤\95 à¤¯à¤¾ à¤\8fà¤\95 à¤¸à¥\87 à¤¢à¥\87र à¤\85à¤\87सन à¤\95à¥\85रà¥\87à¤\95à¥\8dà¤\9fर à¤¹à¥\8b à¤¸à¤\95त à¤¬à¤¾ à¤\9cवन à¤¶à¥\80रà¥\8dषà¤\95 à¤®à¥\87à¤\82 à¤ªà¥\8dरयà¥\8bà¤\97 à¤¨à¤\87à¤\96à¥\87 à¤\95à¤\87ल à¤\9cा à¤¸à¤\95त।",
-       "title-invalid-empty": "माà¤\81à¤\97ल à¤\9cा à¤°à¤¹à¤² à¤ªà¤¨à¥\8dना à¤\9fाà¤\87à¤\9fिल à¤¯à¤¾ à¤¤ à¤\96ालà¥\80 à¤¬à¤¾ à¤¯à¤¾ à¤«à¤¿à¤° à¤\96ालà¥\80 à¤\95à¥\8cनà¥\8bà¤\82 à¤¨à¤¾à¤\81वसà¥\8dथान à¤\95à¥\87 à¤¨à¤¾à¤\81व à¤­à¤° à¤¦à¤¿à¤¹à¤² à¤\97à¤\87ल à¤¬à¤¾à¤\9fà¥\87।",
+       "badtitletext": "à¤\85नà¥\81रà¥\8bधित à¤\9fाà¤\87à¤\9fिल à¤\85वà¥\88ध, à¤\96ालà¥\80 à¤¯à¤¾ à¤\97लत à¤\9cà¥\81ड़ल à¤\85à¤\82तर-भाषà¥\80य à¤¯à¤¾ à¤\85à¤\82तर-विà¤\95ि à¤\9fाà¤\87à¤\9fिल à¤¬à¤¾à¥¤\nबà¥\81à¤\9dात à¤¬à¤¾ à¤\95ि à¤\8fह à¤®à¥\87à¤\82 à¤\9fाà¤\87à¤\9fिल à¤®à¥\87à¤\82 à¤¨à¤¾ à¤\87सà¥\8dतà¥\87माल à¤¹à¥\8b à¤¸à¤\95à¥\87 à¤²à¤¾à¤¯à¤\95 à¤\8fà¤\95 à¤¯à¤¾ à¤\8fà¤\95 à¤¸à¥\87 à¤¢à¥\87र à¤\95à¥\85रà¥\87à¤\95à¥\8dà¤\9fर à¤¬à¤¾।",
+       "title-invalid-empty": "माँगल जा रहल पन्ना टाइटिल या त खाली बा या फिर कौनों नाँवस्थान के नाँव भर दिहल गइल बाटे।",
        "title-invalid-utf8": "माँगल जा रहल पन्ना टाइटिल में अइसन UTF-8 सीक्वेंस बा जेवन मान्य नइखे।",
        "title-invalid-interwiki": "माँगल जा रहल पन्ना टाइटिल में इंटरविकि कड़ी बा जेवन टाइटिल में ना प्रयोग कइल जा सकत बा।",
        "title-invalid-talk-namespace": "माँगल जा रहल पन्ना टाइटिल एगो अइसन वार्ता पन्ना के रेफर करत बा जेवना के होखल संभव नइखे।",
        "title-invalid-magic-tilde": "माँगल जा रहल पन्ना टाइटिल में अमान्य जादुई टिल्ड सीक्वेंस (<nowiki>~~~</nowiki>) बाटे।",
        "title-invalid-too-long": "माँगल जा रहल पन्ना टाइटिल बहुत ढेर लंबा बा। ई UTF-8 की एनकोडिंग में $1 {{PLURAL:$1|बाइट|बाइट्स}} से ढेर ना होखे के चाहीं।",
        "title-invalid-leading-colon": "माँगल जा रहल पन्ना टाइटिल में सुरुआते में अमान्य कोलन (:) बाटे।",
-       "perfcached": "नà¥\80à¤\9aà¥\87 à¤¦à¤¿à¤¹à¤² à¤\97à¤\87ल à¤¡à¥\87à¤\9fा à¤\95à¥\88शà¥\87 à¤®à¥\87मà¥\8bरà¥\80 à¤¸à¥\87 à¤²à¤¿à¤¹à¤² à¤\97à¤\87ल à¤¬à¤¾, à¤\85तà¤\83 à¤¹à¥\8b à¤¸à¤\95ता à¤¬à¤¾ à¤\95ि à¤\87 à¤\95à¥\87 à¤ªà¥\82रà¥\8dण à¤\85दà¥\8dयतन à¤¨à¤¾ à¤­à¤\87ल à¤¹à¥\8bà¤\96à¥\87। à¤\95à¥\88शà¥\87 à¤®à¥\87मà¥\8bरà¥\80 à¤®à¥\87à¤\82 à¤\85धिà¤\95तम {{PLURAL:$1|à¤\8fà¤\95  à¤¨à¤¤à¥\80à¤\9cा|$1 à¤¨à¤¤à¥\80à¤\9cà¤\82}} à¤\89पलबà¥\8dध à¤¬à¤¾à¤¡à¤¼à¥\87।",
-       "perfcachedts": "नà¥\80à¤\9aà¥\87 à¤¦à¤¿à¤¹à¤² à¤\97à¤\87ल à¤¡à¥\87à¤\9fा à¤\95à¥\88शà¥\87 à¤®à¥\87मà¥\8bरà¥\80 à¤¸à¥\87 à¤¬à¤¾, à¤\86 à¤\8fà¤\95र à¤\85à¤\82तिम à¤\85पडà¥\87à¤\9f $1 à¤\95à¥\87 à¤­à¤\87ल à¤°à¤¹à¤²à¥¤ à¤\95à¥\88श à¤®à¥\87मà¥\8bरà¥\80 à¤®à¥\87à¤\82 à¤\85धिà¤\95तम {{PLURAL:$4|à¤\8fà¤\95  à¤¨à¤¤à¥\80à¤\9cा|$4 à¤¨à¤¤à¥\80à¤\9cाà¤\82}} उपलब्ध बा।",
-       "querypage-no-updates": "à¤\87 à¤ªà¥\83षà¥\8dठ à¤\95à¥\87 à¤\85पडà¥\87à¤\9f à¤\95रल à¤\85यà¥\8bà¤\97à¥\8dय à¤¬à¤¾à¥¤ à¤\85भà¥\80 à¤\85हिà¤\9cा à¤\95à¥\87 à¤¡à¤¾à¤\9fा à¤\95à¥\87 à¤¤à¤¾à¤\9c़ा à¤¨à¤\87à¤\96à¥\87 à¤\95रल जा सकत।",
+       "perfcached": "नà¥\80à¤\9aà¥\87 à¤¦à¤¿à¤¹à¤² à¤\97à¤\87ल à¤\86à¤\81à¤\95ड़ा à¤\95à¥\88शà¥\87 à¤®à¥\87मà¥\8bरà¥\80 à¤¸à¥\87 à¤²à¤¿à¤¹à¤² à¤\97à¤\87ल à¤¬à¤¾, à¤¹à¥\8b à¤¸à¤\95ता à¤¬à¤¾ à¤\95ि à¤\88 à¤\8fà¤\95दम à¤\85पडà¥\87à¤\9f à¤¨à¤¾ à¤¹à¥\8bà¤\96à¥\87। à¤\95à¥\88शà¥\87 à¤®à¥\87मà¥\8bरà¥\80 à¤®à¥\87à¤\82 à¤\85धिà¤\95तम {{PLURAL:$1|à¤\8fà¤\95 à¤ à¥\8b  à¤¨à¤¤à¥\80à¤\9cा|$1 à¤¨à¤¤à¥\80à¤\9cा}} à¤\89पलबà¥\8dध à¤¬à¤¾।",
+       "perfcachedts": "नà¥\80à¤\9aà¥\87 à¤¦à¤¿à¤¹à¤² à¤\97à¤\87ल à¤\86à¤\81à¤\95ड़ा à¤\95à¥\88शà¥\87 à¤®à¥\87मà¥\8bरà¥\80 à¤¸à¥\87 à¤¬à¤¾, à¤\86 à¤\8fà¤\95र à¤\85à¤\82तिम à¤\85पडà¥\87à¤\9f $1 à¤\95à¥\87 à¤­à¤\87ल à¤°à¤¹à¤²à¥¤ à¤\95à¥\88श à¤®à¥\87मà¥\8bरà¥\80 à¤®à¥\87à¤\82 à¤\85धिà¤\95तम {{PLURAL:$4|à¤\8fà¤\95 à¤ à¥\8b à¤¨à¤¤à¥\80à¤\9cा|$4 à¤¨à¤¤à¥\80à¤\9cा}} उपलब्ध बा।",
+       "querypage-no-updates": "à¤\8fह à¤ªà¤¨à¥\8dना à¤¸à¥\87 à¤¸à¤\82बà¤\82धित à¤\85पडà¥\87à¤\9f à¤µà¤°à¥\8dतमान à¤®à¥\87à¤\82 à¤¨à¤¿à¤°à¤¸à¥\8dत à¤¬à¤¾à¥¤ à¤\85भà¥\80 à¤\85हिà¤\9cा à¤\95à¥\87 à¤¡à¤¾à¤\9fा à¤\95à¥\87 à¤¤à¤¾à¤\9cा à¤¨à¤\87à¤\96à¥\87 à¤\95à¤\87ल जा सकत।",
        "viewsource": "स्रोत देखीं",
        "viewsource-title": "$1 के स्रोत देखीं",
-       "actionthrottled": "à¤\95ारà¥\8dय समाप्त कर दिहल गइल बा",
-       "actionthrottledtext": "दुरुपयोग रोकथाम उपाय के रूप में, एह काम के बहुत कम समय में एक सीमा से अधिक बे करे के मना बा, आ रउआ ई सीमा के पार कर चुकल बानी।\nकृपया कुछ समय बाद दोबारा कोसिस करीं।",
-       "protectedpagetext": "à¤\87 à¤ªà¤¨à¥\8dना à¤¸à¤\82पादन à¤\86 à¤\85नà¥\8dय à¤\95ारà¥\8dयà¤\82 à¤¸à¥\87 à¤¬à¤\9aाव खातिर सुरक्षित कर दिहल गइल बा।",
+       "actionthrottled": "à¤\95ारà¥\8dरवाà¤\88 समाप्त कर दिहल गइल बा",
+       "actionthrottledtext": "दुरुपयोग रोकथाम उपाय के रूप में, एह काम के बहुत कम समय में एक सीमा से अधिक बे करे के मना बा, आ रउआ ई सीमा के पार कर चुकल बानी।\nकृपया कुछ समय बाद दोबारा कोसिस करीं।",
+       "protectedpagetext": "à¤\8f à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤¸à¤\82पादन à¤\86 à¤\85नà¥\8dय à¤\95ारà¥\8dरवाà¤\88 à¤¸à¥\87 à¤¬à¤\9aावà¥\87 खातिर सुरक्षित कर दिहल गइल बा।",
        "viewsourcetext": "रउआँ एह पन्ना के स्रोत देख सकत बानी आ एकर नकल उतार सकत बानी:",
-       "viewyourtext": "à¤\8fह à¤ªà¤¨à¥\8dना à¤ªà¤° <strong>राà¤\89र à¤\86पन à¤¸à¤\82पादन à¤¸à¤¬</strong>के स्रोत देख सकत बानी आ ओकर नकल ले सकत बानी।",
-       "protectedinterface": "à¤\87 à¤ªà¤¨à¥\8dना à¤\87 à¤µà¤¿à¤\95à¥\80 à¤\95à¥\87 à¤¸à¥\89फ़à¥\8dà¤\9fवà¥\87यर à¤\95à¥\87 à¤\87à¤\82à¤\9fरफ़à¥\87स à¤ªà¤¾à¤ à¥\8dय à¤\95à¥\87 à¤¦à¥\87वà¥\87ला, à¤\86 à¤\87 à¤\95à¥\87 à¤\97लत à¤ªà¥\8dरयà¥\8bà¤\97 à¤¸à¥\87 à¤¬à¤\9aावà¥\87 à¤\96ातिर à¤¸à¥\81रà¤\95à¥\8dषित à¤\95र à¤¦à¤¿à¤¹à¤² à¤\97à¤\87ल à¤¬à¤¾à¥¤\nसभन à¤µà¤¿à¤\95ियन à¤\96ातिर à¤\85नà¥\81वाद à¤\9cà¥\8bड़à¥\87 à¤¯à¤¾ à¤¬à¤¦à¤²à¥\87 à¤\96ातिर à¤\95à¥\83पया à¤®à¥\80डियाविà¤\95ि à¤\95à¥\87 à¤\95à¥\8dषà¥\87तà¥\8dरà¥\80यà¤\95रण à¤ªà¥\8dरà¤\95लà¥\8dप [https://translatewiki.net/ translatewiki.net] à¤\95à¥\87 à¤ªà¥\8dरयà¥\8bà¤\97 करीं।",
-       "editinginterface": "<strong>à¤\9aà¥\87तावनà¥\80:</strong> à¤\86प à¤\8fà¤\97à¥\8b à¤\85à¤\87सन à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤¬à¤¦à¤² à¤¬à¤¦à¤² à¤°à¤¹à¤² à¤¬à¤¾à¤¨à¥\80 à¤\9cवन à¤¸à¥\89फ़à¥\8dà¤\9fवà¥\87यर à¤\95à¥\87 à¤\87à¤\82à¤\9fरफ़à¥\87स à¤ªà¤¾à¤  à¤ªà¥\8dरदान à¤\95रà¥\87ला। à¤\87 à¤ªà¥\83षà¥\8dठ à¤\95à¥\87 à¤¬à¤¦à¤²à¥\87 à¤¸à¥\87 à¤\85नà¥\8dय à¤¸à¤¦à¤¸à¥\8dयवन à¤\95à¥\87 à¤ªà¥\8dरदरà¥\8dशित à¤\87à¤\82à¤\9fरफ़à¥\87स à¤\95à¥\87 à¤¶à¤\95à¥\8dलà¥\8bसà¥\82रत à¤®à¥\87à¤\82 à¤¬à¤¦à¤²à¤¾à¤µ à¤\86à¤\88।",
+       "viewyourtext": "à¤\8fह à¤ªà¤¨à¥\8dना à¤ªà¤° <strong>à¤\86पन à¤\96à¥\81द à¤\95à¥\87 à¤¸à¤\82पादन</strong>के स्रोत देख सकत बानी आ ओकर नकल ले सकत बानी।",
+       "protectedinterface": "à¤\88 à¤ªà¤¨à¥\8dना à¤\8fह à¤µà¤¿à¤\95ि à¤\95à¥\87 à¤¸à¥\89फà¥\8dà¤\9fवà¥\87यर à¤\95à¥\87 à¤\87à¤\82à¤\9fरफà¥\87स à¤ªà¤¾à¤  à¤\89पलबà¥\8dध à¤\95रावà¥\87 à¤²à¤¾, à¤\86 à¤¦à¥\81रà¥\82पयà¥\8bà¤\97 à¤°à¥\8bà¤\95à¥\87 à¤\96ातिर à¤\8fà¤\95रा à¤\95à¥\87 à¤¸à¥\81रà¤\95à¥\8dषित à¤\95र à¤¦à¤¿à¤¹à¤² à¤\97à¤\87ल à¤¬à¤¾à¥¤\nबिनमà¥\8dर à¤\85नà¥\81रà¥\8bध à¤¬à¤¾ à¤\95ि, à¤¸à¤\97रà¥\80 à¤µà¤¿à¤\95ि à¤¸à¤­ à¤\96ातिर à¤\85नà¥\81वाद à¤\95रà¥\87 à¤¯à¤¾ à¤\85नà¥\81वाद à¤®à¥\87à¤\82 à¤¬à¤¦à¤²à¤¾à¤µ à¤\95रà¥\87 à¤\96ातिर à¤®à¥\80डियाविà¤\95ि à¤\95à¥\87 à¤²à¥\8bà¤\95लाà¤\87à¤\9cà¥\87शन à¤ªà¥\8dरà¥\8bà¤\9cà¥\87à¤\95à¥\8dà¤\9f [https://translatewiki.net/ translatewiki.net] à¤\95à¥\87 à¤\87सà¥\8dतà¥\87माल करीं।",
+       "editinginterface": "<strong>à¤\9aà¥\87तावनà¥\80:</strong> à¤\86प à¤\8fà¤\97à¥\8b à¤\85à¤\87सन à¤ªà¤¨à¥\8dना à¤\95à¥\87 à¤¸à¤\82पादन à¤\95र à¤°à¤¹à¤² à¤¬à¤¾à¤¨à¥\80 à¤\9cवन à¤¸à¥\89फà¥\8dà¤\9fवà¥\87यर à¤\95à¥\87 à¤\87à¤\82à¤\9fरफà¥\87स à¤ªà¤¾à¤  à¤\89पलबà¥\8dध à¤\95रावà¥\87 à¤²à¤¾à¥¤ à¤\8fह à¤ªà¤¨à¥\8dना à¤ªà¤° à¤¹à¥\8bà¤\96à¥\87 à¤µà¤¾à¤²à¤¾ à¤¬à¤¦à¤²à¤¾à¤µ à¤\8fह à¤µà¤¿à¤\95ि à¤ªà¤° à¤\95à¥\87 à¤\85नà¥\8dय à¤ªà¥\8dरयà¥\8bà¤\97à¤\95रà¥\8dता à¤²à¥\8bà¤\97 à¤\95à¥\87 à¤²à¤\89à¤\95à¥\87 à¤µà¤¾à¤²à¤¾ à¤\87à¤\82à¤\9fरफà¥\87स à¤\95à¥\87 à¤¸à¤\95लसà¥\82रत à¤\95à¥\87 à¤ªà¤°à¤­à¤¾à¤µà¤¿à¤¤ à¤\95रà¥\80।",
        "translateinterface": "सभन विकियन खातिर अनुवाद जोड़े या बदले खातिर मीडियाविकि क्षेत्रीयकरण परियोजना [https://translatewiki.net/ translatewiki.net] के प्रयोग करीं।",
        "cascadeprotected": "ए पन्ना के संपादन कइल सुरक्षित क दिहल गइल बा काहें कि ई {{PLURAL:$1|पन्ना में, जौना के|पन्ना सब में, जिन्हन के}} \"कैस्केडिंग\" (बिस्तारित) सुरक्षा चालू क के सुरक्षित कइल गइल बा, में समाइल बाटे:\n$2",
        "namespaceprotected": "रउआ के '''$1''' नामस्थान के पन्नं में सम्पादन करे के अधिकार नइखे दिहल गइल।",
        "passwordreset-emaildisabled": "इ विकि पर ई-मेल सुविधा अक्षम कर दिहल गईल बा।",
        "passwordreset-username": "प्रयोगकर्ता नाम",
        "passwordreset-domain": "डोमेन:",
-       "passwordreset-capture": "परिणामस्वरूप बनल ई-मेल देखब?",
-       "passwordreset-capture-help": "अगर रउआ इ चेकबॉक्स पर टिक करत बानी त ई-मेल (अस्थायी गुप्तशब्द के साथ) रउआ के दिखावल जाई आ सदस्य के भेजल भी जाई।",
        "passwordreset-email": "ई-मेल पता:",
        "passwordreset-emailtitle": "{{SITENAME}} पर खाता विवरण",
        "passwordreset-emailtext-ip": "केहु (शायद रउए, $1 आइ॰पी पता से) {{SITENAME}} ($4) पर आपन {{PLURAL:$3|गुप्तशब्द}} के रीसेट करे के अनुरोध कईले बानी। इ ई-मेल पता से निम्न {{PLURAL:$3|खाता जुड़ल बा}}:\n\n$2\n\n{{PLURAL:$3|इ}} अस्थायी गुप्तशब्द {{PLURAL:$5|एक दिन|$5 दिन}} के बाद काम ना करी। रउआ खाता में प्रवेश करके एगो नया गुप्तशब्द अभी चुन लेवे के चाहीं। यदि इ अनुरोध केहु अउर कइले बा, या फिर रउआ आपन मूल गुप्तशब्द याद आ गईल बा, अउर आप {{PLURAL:$3|आपन}} गुप्तशब्द नइखी बदले के चाहत त, रउआ इ संदेश के अनदेखा कर के आपन पुरानका गुप्तशब्द के प्रयोग जारी रख सकत बानी।",
        "tooltip-p-logo": "मुख्य पन्ना पर जाईं",
        "tooltip-n-mainpage": "मुख्य पन्ना पर जाईं",
        "tooltip-n-mainpage-description": "मुख्य पन्ना पर जाईं",
-       "tooltip-n-portal": "पà¥\8dरà¥\8bà¤\9cà¥\87à¤\95à¥\8dà¤\9f à¤\95à¥\80 à¤¬à¤¾à¤°à¥\87 à¤®à¥\87à¤\81, रउआँ का कर सकत बानी, कौनों चीज कहाँ खोजब",
+       "tooltip-n-portal": "पà¥\8dरà¥\8bà¤\9cà¥\87à¤\95à¥\8dà¤\9f à¤\95à¥\80 à¤¬à¤¾à¤°à¥\87 à¤®à¥\87à¤\82, रउआँ का कर सकत बानी, कौनों चीज कहाँ खोजब",
        "tooltip-n-currentevents": "वर्तमान के घटना पर पृष्ठभूमी जानकारी खोजीं",
        "tooltip-n-recentchanges": "विकि पर तुरंत भइल बदलाव के लिस्ट",
        "tooltip-n-randompage": "बेतरतीब पन्ना लोड करीं",
index 4bd05be..58781ab 100644 (file)
        "emailuserfooter": "এই ইমেইলটি {{SITENAME}} সাইটের \"{{int:emailuser}}\" সুবিধা ব্যবহার করে $1-এর পক্ষ থেকে {{GENDER:$2|$2}}-এর নিকট {{GENDER:$1|পাঠানো হয়েছে}}।",
        "usermessage-summary": "বাদবাকি সিস্টেম বার্তা",
        "usermessage-editor": "সিস্টেম ম্যাসেঞ্জার",
+       "usermessage-template": "MediaWiki:ব্যবহারকারী বার্তা",
        "watchlist": "নজর তালিকা",
        "mywatchlist": "নজর তালিকা",
        "watchlistfor2": "$1 ($2)-এর জন্য",
        "hijri-calendar-m11": "জ্বিলকদ",
        "hijri-calendar-m12": "জ্বিলহজ্জ",
        "hebrew-calendar-m1": "তিশরেই",
+       "hebrew-calendar-m2": "হেশভান",
+       "hebrew-calendar-m3": "কিসলেভ",
+       "hebrew-calendar-m4": "তেভেত",
+       "hebrew-calendar-m5": "শেভাত",
+       "hebrew-calendar-m6": "আদার",
+       "hebrew-calendar-m6a": "আদার ১",
+       "hebrew-calendar-m6b": "আদার ২",
+       "hebrew-calendar-m7": "নিসান",
+       "hebrew-calendar-m8": "ইয়্যার",
+       "hebrew-calendar-m9": "সিভান",
        "hebrew-calendar-m10": "তামুয",
        "hebrew-calendar-m11": "আভ",
        "hebrew-calendar-m12": "এলুল",
+       "hebrew-calendar-m1-gen": "তিশরি",
+       "hebrew-calendar-m2-gen": "হেশভান",
+       "hebrew-calendar-m3-gen": "কিসলেভ",
+       "hebrew-calendar-m4-gen": "তেভেত",
+       "hebrew-calendar-m5-gen": "শেভাত",
+       "hebrew-calendar-m6-gen": "আদার",
+       "hebrew-calendar-m6a-gen": "আদার ১",
+       "hebrew-calendar-m6b-gen": "আদার ২",
        "hebrew-calendar-m7-gen": "নিসান",
+       "hebrew-calendar-m8-gen": "ইয়্যার",
+       "hebrew-calendar-m9-gen": "সিভান",
+       "hebrew-calendar-m10-gen": "তামুয",
+       "hebrew-calendar-m11-gen": "আভ",
+       "hebrew-calendar-m12-gen": "এলুল",
        "signature": "[[{{ns:user}}:$1|$2]] ([[{{ns:user_talk}}:$1|আলাপ]])",
        "timezone-utc": "ইউটিসি",
        "timezone-local": "স্থানীয়",
        "mw-widgets-dateinput-no-date": "কোন তারিখ নির্বাচন করা হয়নি",
        "mw-widgets-dateinput-placeholder-day": "বববব-মম-দদ",
        "mw-widgets-dateinput-placeholder-month": "বববব-মম",
+       "mw-widgets-mediasearch-input-placeholder": "মিডিয়ার জন্য অনুসন্ধান",
+       "mw-widgets-mediasearch-noresults": "কোনো ফলাফল পাওয়া যায়নি।",
        "mw-widgets-titleinput-description-new-page": "পাতা এখনো বিদ্যমান নয়",
        "mw-widgets-titleinput-description-redirect": "$1-এ পুনঃনির্দেশিত",
        "mw-widgets-categoryselector-add-category-placeholder": "একটি বিষয়শ্রেণী যোগ করুন...",
index 05b3b12..2a3c356 100644 (file)
        "userpage-userdoesnotexist": "Korisnički račun \"<nowiki>$1</nowiki>\" nije registrovan.\nMolimo provjerite da li želite napraviti/izmijeniti ovu stranicu.",
        "userpage-userdoesnotexist-view": "Korisnički račun \"$1\" nije registrovan.",
        "blocked-notice-logextract": "Ovaj korisnik je trenutno blokiran.\nPosljednje stavke zapisnika blokiranja možete pogledati ispod:",
-       "clearyourcache": "'''Pažnja:''' Nakon što sačuvate izmjene, morate \"osvježiti\" keš memoriju vašeg pretraživača da bi ste vidjeli nova podešenja.'''\n*'''Firefox / Safari:''' držite ''Shift'' tipku i kliknite na ''Reload'' dugme ili pritisnite ''Ctrl-F5'' ili ''Ctrl-R'' (''⌘-R'' na Macu)\n*'''Google Chrome:''' pritisnite ''Ctrl-Shift-R'' (''⌘-Shift-R'' na Macu)\n*'''Internet Explorer:''' držite tipku ''Ctrl'' i kliknite na ''Refresh'' ili pritisnite ''Ctrl-F5''\n*'''Opera:''' očistite \"keš\" preko izbornika ''Tools → Preferences''",
+       "clearyourcache": "<strong>Napomena:</strong> Nakon što sačuvate izmjene, možda ćete morati osvježiti keš preglednika da biste vidjeli izmjene.\n* <strong>Firefox / Safari:</strong> Držite <em>Shift</em> i kliknite na <em>Reload</em> ili pritisnite <em>Ctrl-F5</em> ili <em>Ctrl-R</em> (<em>⌘-R</em> na Macu)\n* <strong>Google Chrome:</strong> Pritisnite <em>Ctrl-Shift-R</em> (<em>⌘-Shift-R</em> na Macu)\n* <strong>Internet Explorer:</strong> Držite <em>Ctrl</em> i kliknite na <em>Refresh</em> ili pritisnite <em>Ctrl-F5</em>\n* <strong>Opera:</strong> Idite na <em>Menu → Settings</em> (<em>Opera → Preferences</em> na Macu) i zatim <em>Privacy & security → Clear browsing data → Cached images and files</em>.",
        "usercssyoucanpreview": "'''Pažnja:''' Koristite dugme \"{{int:showpreview}}\" da testirate svoj novi CSS prije nego što sačuvate.",
        "userjsyoucanpreview": "'''Pažnja:''' Koristite dugme \"{{int:showpreview}}\" da testirate svoj novi JavaScript prije nego što sačuvate.",
        "usercsspreview": "'''Zapamtite ovo je samo izgled Vašeg CSS-a.'''\n'''Ovaj pregled još uvijek nije sačuvan!'''",
index 2c3c41c..1574bb1 100644 (file)
        "invalid-content-data": "Dades de contingut no vàlides",
        "content-not-allowed-here": "No és permès el contingut \"$1\" a la pàgina [[$2]]",
        "editwarning-warning": "Si sortiu d'aquesta pàgina, perdreu tots els canvis que hàgiu fet.\nSi teniu un compte d'usuari, podeu eliminar aquest avís en la secció «{{int:prefs-editing}}» de les vostres preferències.",
+       "editpage-invalidcontentmodel-title": "Model de contingut no permès",
+       "editpage-invalidcontentmodel-text": "El model de contingut «$1» no és permès.",
        "editpage-notsupportedcontentformat-title": "No s'admet el format del contingut",
        "editpage-notsupportedcontentformat-text": "No s'admet el format del contingut $1 pel model de contingut $2.",
        "content-model-wikitext": "wikitext",
        "editusergroup": "Carrega els grups d'usuari",
        "editinguser": "Modificació dels permisos de {{GENDER:$1|l'usuari|la usuària}} <strong>[[User:$1|$1]]</strong>$2",
        "userrights-editusergroup": "Edita els grups d'usuaris",
+       "userrights-viewusergroup": "Mostra els grups d'usuari",
        "saveusergroups": "Desa els grups d'{{GENDER:$1|usuari}}",
        "userrights-groupsmember": "Membre de:",
        "userrights-groupsmember-auto": "Membre implícit de:",
        "action-upload_by_url": "carregar aquest fitxer des d'una adreça URL",
        "action-writeapi": "fer servir l'API d'escriptura",
        "action-delete": "esborrar aquesta pàgina",
-       "action-deleterevision": "esborrar aquesta revisió",
-       "action-deletedhistory": "visualitzar l'historial esborrat d'aquesta pàgina",
+       "action-deleterevision": "suprimeix les revisions",
+       "action-deletelogentry": "suprimeix les entrades de registre",
+       "action-deletedhistory": "mostra l'historial esborrat d'una pàgina",
        "action-browsearchive": "cercar pàgines esborrades",
        "action-undelete": "recuperar aquesta pàgina",
        "action-suppressrevision": "revisar i recuperar aquesta revisió oculta",
        "action-userrights-interwiki": "modificar permisos d'usuari en altres wikis",
        "action-siteadmin": "bloquejar o desbloquejar la base de dades",
        "action-sendemail": "enviar missatges de correu",
+       "action-editmyoptions": "modifiqueu les vostres preferències",
        "action-editmywatchlist": "edita la llista de seguiment",
        "action-viewmywatchlist": "mostra la llista de seguiment",
        "action-viewmyprivateinfo": "mostra la informació personal",
        "sessionprovider-nocookies": "Pot ser que les galetes estiguin inhabilitades. Assegureu-vos que teniu les galetes habilitades i inicieu de nou.",
        "randomrootpage": "Pàgina arrel aleatòria",
        "log-action-filter-block": "Tipus de blocatge:",
+       "log-action-filter-contentmodel": "Tipus de modificació del model de contingut:",
        "log-action-filter-delete": "Tipus de supressió:",
        "log-action-filter-import": "Tipus d'importació:",
        "log-action-filter-managetags": "Tipus d'acció de gestió d'etiquetes:",
        "log-action-filter-block-block": "Bloca",
        "log-action-filter-block-reblock": "Bloca la modificació",
        "log-action-filter-block-unblock": "Desbloca",
+       "log-action-filter-contentmodel-change": "Canvi del model de contingut",
        "log-action-filter-delete-delete": "Supressió de pàgines",
        "log-action-filter-delete-delete_redir": "Sobreescriptura de la redirecció",
        "log-action-filter-delete-restore": "Restauració de pàgines",
        "cannotauth-not-allowed": "No teniu permisos per utilitzar la pàgina",
        "changecredentials": "Canvi de dades credencials",
        "changecredentials-submit": "Canvia les dades credencials",
+       "removecredentials": "Suprimeix les credencials",
+       "removecredentials-submit": "Suprimeix les credencials",
+       "removecredentials-success": "S'ha suprimit les vostres credencials.",
        "credentialsform-provider": "Tipus de dades credencials:",
        "credentialsform-account": "Nom del compte:",
        "cannotlink-no-provider-title": "No hi ha cap compte enllaçable",
        "unlinkaccounts": "Desenllaça els comptes",
        "unlinkaccounts-success": "El compte s'ha desenllaçat.",
        "authenticationdatachange-ignored": "No s'ha gestionat el canvi de dades d'autenticació. Potser no s'ha configurat cap proveïdor?",
-       "restrictionsfield-label": "Intervals d'IP permesos:"
+       "restrictionsfield-badip": "Adreça o interval d'IP no vàlid: $1",
+       "restrictionsfield-label": "Intervals d'IP permesos:",
+       "pageid": "ID de pàgina $1"
 }
index d1d4670..7c54e02 100644 (file)
        "userrights-user-editname": "Zadejte uživatelské jméno:",
        "editusergroup": "Načíst uživatelské skupiny",
        "editinguser": "Úprava práv {{GENDER:$1|uživatele|uživatelky}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "Prohlížení práv {{GENDER:$1|uživatele|uživatelky}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Upravit uživatelské skupiny",
+       "userrights-viewusergroup": "Zobrazit uživatelské skupiny",
        "saveusergroups": "Uložit {{GENDER:$1|uživatelské}} skupiny",
        "userrights-groupsmember": "{{GENDER:$2|Člen|Členka}} {{PLURAL:$1|skupiny|skupin}}:",
        "userrights-groupsmember-auto": "Automaticky {{GENDER:$2|člen|členka}} {{PLURAL:$1|skupiny|skupin}}:",
index 86ae2e8..4ae7a73 100644 (file)
        "userrights-user-editname": "Benutzername:",
        "editusergroup": "Benutzergruppen laden",
        "editinguser": "Ändere Benutzerrechte {{GENDER:$1|des Benutzers|der Benutzerin}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "Benutzerrechte {{GENDER:$1|des Benutzers|der Benutzerin}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Benutzer-Gruppenzugehörigkeit bearbeiten",
+       "userrights-viewusergroup": "Benutzergruppen ansehen",
        "saveusergroups": "{{GENDER:$1|Gruppenzugehörigkeit}} ändern",
        "userrights-groupsmember": "Mitglied von:",
        "userrights-groupsmember-auto": "Automatisch Mitglied von:",
        "action-writeapi": "die API mit Schreibzugriffen zu verwenden",
        "action-delete": "Seiten zu löschen",
        "action-deleterevision": "Versionen zu löschen",
+       "action-deletelogentry": "Logbucheinträge zu löschen",
        "action-deletedhistory": "die Liste der gelöschten Versionen zu sehen",
+       "action-deletedtext": "gelöschten Versionstext anzusehen",
        "action-browsearchive": "nach gelöschten Seiten zu suchen",
-       "action-undelete": "die Seite wiederherzustellen",
-       "action-suppressrevision": "die versteckte Version einzusehen und wiederherzustellen",
+       "action-undelete": "Seiten wiederherzustellen",
+       "action-suppressrevision": "versteckte Versionen einzusehen und wiederherzustellen",
        "action-suppressionlog": "das private Logbuch einzusehen",
        "action-block": "den Benutzer zu sperren",
        "action-protect": "den Schutzstatus von Seiten zu ändern",
        "action-userrights-interwiki": "die Rechte von Benutzern in anderen Wikis zu ändern",
        "action-siteadmin": "die Datenbank zu sperren oder freizugeben",
        "action-sendemail": "E-Mails zu senden",
+       "action-editmyoptions": "deine Einstellungen zu bearbeiten",
        "action-editmywatchlist": "deine Beobachtungsliste zu bearbeiten",
        "action-viewmywatchlist": "deine Beobachtungsliste anzusehen",
        "action-viewmyprivateinfo": "deine privaten Informationen einzusehen",
        "usercssispublic": "Bitte beachten: CSS-Unterseiten sollten keine vertraulichen Daten enthalten, da sie von anderen Benutzern eingesehen werden können.",
        "restrictionsfield-badip": "Ungültige IP-Adresse oder ungültiger IP-Adressbereich: $1",
        "restrictionsfield-label": "Erlaubte IP-Adressbereiche:",
-       "restrictionsfield-help": "Eine IP-Adresse oder ein CIDR-Bereich pro Zeile. Um alles zu aktivieren, verwende<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "Eine IP-Adresse oder ein CIDR-Bereich pro Zeile. Um alles zu aktivieren, verwende<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "revid": "v$1",
+       "pageid": "Seitenkennung $1"
 }
index 2f684cc..0950300 100644 (file)
        "categoryviewer-pagedlinks": "($1) ($2)",
        "about": "Heqa cı de",
        "article": "Pela zerreki",
-       "newwindow": "(pençereyê newey de beno a)",
-       "cancel": "İbtal",
+       "newwindow": "(pençerey newey de beno a)",
+       "cancel": "Bıtexelne",
        "moredotdotdot": "Vêşi...",
        "morenotlisted": "Na lista qay kemi ya.",
        "mypage": "Pele",
        "history": "Tarixê pele",
        "history_short": "Tarix",
        "updatedmarker": "cıkewtena mına peyêne ra dıme biyo rocane",
-       "printableversion": "Asayışê çap kerdışi",
+       "printableversion": "Asayışê çapkerdışi",
        "permalink": "Gıreyo bêpeyni",
        "print": "Çap ke",
        "view": "Bıvêne",
        "unprotectthispage": "Starkerdışe ena peler bıvurne",
        "newpage": "Pela newiye",
        "talkpage": "Ena pele sero werêne",
-       "talkpagelinktext": "behs",
-       "specialpage": "Pella xısusi",
+       "talkpagelinktext": "Mesac",
+       "specialpage": "Pelê hısusiy",
        "personaltools": "Hacetê şexsiy",
        "articlepage": "Pera zerreki bıvin",
-       "talk": "Behs",
+       "talk": "Werênayış",
        "views": "Asayışi",
        "toolbox": "Haceti",
        "tool-link-userrights": "Grubanê {{GENDER:$1|karberi}} bıvırnë",
        "viewhelppage": "Pera peşti bıvin",
        "categorypage": "Pela kategoriya bıasne",
        "viewtalkpage": "Werênayışi bıvêne",
-       "otherlanguages": "Zederna zıwani",
+       "otherlanguages": "Zıwananê binan dı",
        "redirectedfrom": "($1 ra kırışı yê)",
        "redirectpagesub": "Pela berdışi",
        "redirectto": "Beno hetê:",
-       "lastmodifiedat": "Per roca $1, sehat $2 de biya anewe.",
+       "lastmodifiedat": "Tewr peyên ena pele $1 dı $2 dı vuriyaya.",
        "viewcount": "Ena pele {{PLURAL:$1|rae|$1 rey}} vêniya.",
        "protectedpage": "Pela pawıtiye",
        "jumpto": "Şo be:",
-       "jumptonavigation": "Pusula",
+       "jumptonavigation": "Navigasyon",
        "jumptosearch": "cı geyre",
        "view-pool-error": "Qaytê qısuri mekerên, serverê ma enıka zêde bar gırewto xo ser.\nHedê xo ra zêde karberi kenê ke seyrê na pele bıkerê.\nŞıma rê zehmet, tenê vınderên, heta ke reyna kenê ke ena pele kewê.\n\n$1",
        "generic-pool-error": "Üzgünüz, şu an sunucular aşırı yüklendi.\nÇok fazla kullanıcı bu sayfayı görüntülemeye çalışıyor.\nLütfen bu sayfaya  tekrar erişmeyi denemeden önce biraz bekleyin.",
        "disclaimerpage": "Project:Redê mesulêtê pêroyi",
        "edithelp": "Peştdariya vurnayışi",
        "helppage-top-gethelp": "Peşti",
-       "mainpage": "Perra Seri",
+       "mainpage": "Pela Seri",
        "mainpage-description": "Pela seri",
        "policy-url": "Project:Terzê hereketi",
        "portal": "Portalê cemaeti",
-       "portal-url": "Project:Portalë Å\9fëlıgi",
+       "portal-url": "Project:Portalê cemaeti",
        "privacy": "Politikay nımıtışi",
        "privacypage": "Project:Xısusiyetê nımıtışi",
        "badaccess": "Xeta mısadey",
        "page-atom-feed": "\"$1\" Cıresnayışê atomi",
        "feed-atom": "Atom",
        "feed-rss": "RSS",
-       "red-link-title": "$1 (perre çıniya)",
+       "red-link-title": "$1 (pele çıniya)",
        "sort-descending": "Rêzkerdışo kêmbiyaye",
        "sort-ascending": "Rêzkerdışo zêdiyaye",
        "nstab-main": "Pele",
-       "nstab-user": "Pella karberi",
+       "nstab-user": "Pela karberi",
        "nstab-media": "Pela medya",
        "nstab-special": "Pela xısusiye",
        "nstab-project": "Pela proceyi",
        "nstab-template": "Şablon",
        "nstab-help": "Pela peşti",
        "nstab-category": "Kategoriye",
-       "mainpage-nstab": "Perra seri",
+       "mainpage-nstab": "Pela seri",
        "nosuchaction": "Fealiyeto wınasi çıniyo",
        "nosuchactiontext": "URL ra kar qebul nêbı.\nŞıma belka URL şaş nuşt, ya zi gıreyi şaş ra ameyi.\nKeyepelê {{SITENAME}} eşkeno xeta eşkera bıkero.",
-       "nosuchspecialpage": "Pella xısusi ya unasin çınya",
+       "nosuchspecialpage": "Pela hısusiya wınasiyên çıniya.",
        "nospecialpagetext": "<strong>To yew pela xasa nêvêrdiye waşte.</strong>\n\nSeba lista pelanê xasanê vêrdeyan reca kena: [[Special:SpecialPages|{{int:specialpages}}]].",
        "error": "Xeta",
        "databaseerror": "Ğetay ardoği",
        "databaseerror-error": "Xeta: $1",
        "laggedslavemode": "Diqet: Pel de newe vıraşteyi belka çini .",
        "readonly": "database kılit biyo",
-       "enterlockreason": "Database kılit biyo",
+       "enterlockreason": "Kılitkerdışi rê tarixê abiyayışê kılit ra piya yew sebeb bınusê.",
        "readonlytext": "Qey pawıtış ri yew sebeb vace. Texmini yew tarix vace şıma key pawıtış wedarneni:  $1",
        "missing-article": "Banqa, pela be nameyê \"$1\" $2 ke gani bıbo, nêdiye.\n\nEna belki seba yew vurnayışo kıhan ya zi tarixê gıreyê yew pele esteriya.\n\nEke wına niyo, belki ''software'' de yew xeta esta.\nKerem kerên, naye be nameyê ''URL''yi yew [[Special:ListUsers/sysop|karber]]i ra vacên.",
        "missingarticle-rev": "(rewizyon#: $1)",
        "perfcached": "Datay cı ver hazır biye. No semedê ra nıkayin niyo! tewr zaf {{PLURAL:$1|netice|$1 netice}} debêno de",
        "perfcachedts": "Cêr de malumatê nımıteyi esti, demdê newe kerdışo peyın: $1. Tewr zaf {{PLURAL:$4|netice|$4 neticey cı}} debyayo de",
        "querypage-no-updates": "Rocanebiyayışê na pele nıka cadayiyê.\nDayiyi tiya nıka newe nêbenê.",
-       "viewsource": "Çımi bıvin",
+       "viewsource": "Çımey bıvêne",
        "viewsource-title": "Cı geyrayışê $1'i bıvin",
        "actionthrottled": "Kerden peysnaya",
        "actionthrottledtext": "Riyê tedbirê anti-spami ra,  wextê do kılmek de şıma nê fealiyeti nêşkenê zaf zêde bıkerê, şıma ki no hedi viyarna ra.\nÇend deqey ra tepeya reyna bıcerrebnên.",
        "welcomecreation-msg": "Hesabê şıma abiyo.\n[[Special:Preferences|{{SITENAME}} vurnayişê tercihanê xo]], xo vir ra mekere.",
        "yourname": "Namey karberi:",
        "userlogin-yourname": "Namey karberi",
-       "userlogin-yourname-ph": "Nameyê xoyê karberi cı kewe",
+       "userlogin-yourname-ph": "Namey xoyê karberi cı kewe",
        "createacct-another-username-ph": "Nameyê karberi cı kewe",
        "yourpassword": "Parola",
        "userlogin-yourpassword": "Parola",
-       "userlogin-yourpassword-ph": "Parolaya xo cıkewe",
+       "userlogin-yourpassword-ph": "Parolay xo cı kewe",
        "createacct-yourpassword-ph": "Parola cıkewe",
        "yourpasswordagain": "Parola reyna bınusne:",
        "createacct-yourpasswordagain": "Parola tesdiq ke",
        "passwordreset-text-many": "{{PLURAL:$1|Qande parola yana e-posta reset kerdışi cayanra taynın pırkeri.}}",
        "passwordreset-disabled": "Parola reset kerdış ena viki sera qefılneyayo.",
        "passwordreset-emaildisabled": "Na wikid hısusiyeté e-posta dewera vıcyayé",
-       "passwordreset-username": "Nameyê karberi:",
+       "passwordreset-username": "Namey karberi:",
        "passwordreset-domain": "Domain:",
        "passwordreset-email": "Adresa e-postey:",
        "passwordreset-emailtitle": "Hesab timarê {{SITENAME}}",
        "bold_tip": "Metno qalın",
        "italic_sample": "Metno çewt",
        "italic_tip": "Metno çewt",
-       "link_sample": "Sernameyê gırey",
-       "link_tip": "Gıreyê miyani",
+       "link_sample": "Sernamey gırey",
+       "link_tip": "Gıreyo zerrên",
        "extlink_sample": "http://www.misal.com sernameyê gırey",
        "extlink_tip": "Gırey teberi (xo vira mekerên http:// prefix)",
        "headline_sample": "metnê sernamey",
        "summary": "Xulasa:",
        "subject": "Mewzu:",
        "minoredit": "No yew vurnayışo werdiyo",
-       "watchthis": "Bıewni ena perrer",
-       "savearticle": "Perrer qeyd kı",
-       "savechanges": "Vuryayışa qeyd kerê",
+       "watchthis": "Bewnı ena pele",
+       "savearticle": "Pele qeyd kı",
+       "savechanges": "Vurnayışan qeyd kı",
        "publishpage": "Perer bıhesırne",
        "publishchanges": "Vurnayışa vıla ke",
        "preview": "Verqayt",
-       "showpreview": "Ver asayışi bıvinê",
-       "showdiff": "Vurriyayışa bıasne",
+       "showpreview": "Verasayışi bımocne",
+       "showdiff": "Vurnayışan bımocne",
        "anoneditwarning": "<strong>İqaz:</strong> Şıma be hesabê xo nêkewtê cı. \nAdresê şımayê IP tarixê vırnayışê na pele de do qeyd bo. Eke şıma <strong>[$1 cıkewê]</strong> ya zi <strong>[$2 hesab vırazê]</strong>, vurnayışê şıma be zewbina kare ra nameyê şıma rê bar beno.",
        "anonpreviewwarning": "\"Şıma be hesabê xo nêkewtê cı. Eke qeyd kerê, adresê şımaê IP tarixê vırnayışê na pele de do qeyd bo.\"",
        "missingsummary": "'''DİQET:''' Şıma jû xulasa nênuşte.\nEke şıma \"{{int:savearticle}}\" reyna bıtıknê, vırnayışê şıma bê xulasa qeyd beno.",
        "token_suffix_mismatch": "'''Vurnayişê şıma tepeya ameyo çunke qutiyê imla xerıbya.\nVurnayişê şıma qey nêxerepyayişê peli tepeya geyra a.\nEke şıma servisê proksi yo anonim şuxulneni sebebê ey noyo.'''",
        "edit_form_incomplete": "'''Qandê form dê vurnayışa tay wastera ma nêreşti; Vurnayışê ke şıma kerdê nêalızyayê, çım ra ravyarnê u fına bıcerbnê.'''",
        "editing": "$1 vuriyeno",
-       "creating": "$1 vıraziyeno",
+       "creating": "$1 vırazeno.",
        "editingsection": "Per da $1 de şımaye kenê ke leti bıvurnê",
        "editingcomment": "$1 vuryeno (qısmo newe)",
        "editconflict": "Têverabiyayışê vurnayışi: $1",
        "templatesusedpreview": "{{PLURAL:$1|Sablon|Sabloni}}  ke na verqayt de xebetnayê:",
        "templatesusedsection": "{{PLURAL:$1|Template|Templateyan}}  ke na qısım de xebetniyenê:",
        "template-protected": "(kılit biyo)",
-       "template-semiprotected": "(nimey ena pele kılit biya)",
+       "template-semiprotected": "(nêmê ena pele kılit biyo)",
        "hiddencategories": "Ena per de {{PLURAL:$1|1 kategoriyo nımıte|$1 kategoriyê nımıtey}} muhtewa benê:",
        "edittools": "<div id=\"specialcharss\" class=\"toccolours specialchars\" style=\"margin-top:.5em; padding: .3em .5em; font-size: 100%; color:#aaa; text-align:left;\" title=\"{{int:bw-edittools-tooltip}}\">\n<p class=\"specialbasic\" id=\"Standard\">\n'''{{int:bw-edittools-lead-in}}''' \n<charinsert>Á á É é Í í Ó ó Ú ú Ý ý</charinsert> –\n<charinsert>À à È è Ì ì Ò ò Ù ù </charinsert> –\n<charinsert> â Ê ê Î î Ô ô Û û </charinsert> –\n<charinsert>Ä ä Ë ë Ï ï Ö ö Ü ü Ÿ ÿ</charinsert> –\n<charinsert>Æ æ Ø ø Œ œ ẞ ß </charinsert> –\n<charinsert>Å å Ů ů </charinsert> –\n<charinsert>àã Ẽ ẽ ɛ̃ Ĩ ĩ Ñ ñ Õ õ ɔ̃ Ũ ũ </charinsert> –\n<charinsert>Рð Þ þ </charinsert> –\n<charinsert>Ç ç Ģ ģ Ķ ķ Ļ ļ Ņ ņ Ŗ ŗ Ş ş Ţ ţ </charinsert> –\n<charinsert>Ć ć Ĺ ĺ Ń ń Ŕ ŕ Ś ś Ý ý Ź ź </charinsert> –\n<charinsert>Č č Ď ď Ľ ľ Ň ň Ř ř Š š Ť ť Ž ž </charinsert> –\n<charinsert>Ǎ ǎ Ě ě Ǐ ǐ Ǒ ǒ Ǔ ǔ </charinsert> –\n<charinsert>Ā ā Ē ē Ī ī Ō ō Ū ū </charinsert> –\n<charinsert>ǖ ǘ ǚ ǜ </charinsert> –\n<charinsert>Ĉ ĉ Ĝ ĝ Ĥ ĥ Ĵ ĵ Ŝ ŝ Ŵ ŵ Ŷ ŷ </charinsert> –\n<charinsert>Ă ă Ğ ğ Ŭ ŭ </charinsert> –\n<charinsert>Ċ ċ Ė ė Ġ ġ Għ għ İ ı Ż ż </charinsert> –\n<charinsert>Ą ą Ę ę Į į Ų ų </charinsert> –\n<charinsert>Ő ő Ű ű </charinsert> –\n<charinsert>Đ đ Ħ ħ Ł ł Ŀ ŀ </charinsert> –\n<charinsert>Ɖ ɖ Ɛ ɛ Ƒ ƒ Ɣ ɣ Ŋ ŋ Ɔ ɔ Ʋ ʋ </charinsert> -\n<charinsert>Ə ə </charinsert> –\n<charinsert>– — ’</charinsert> –\n<charinsert>~ | ° ¹ ² ³ ⅛ ¼ ⅓ ⅜ ½ ⅝ ¾ ⅔ ⅞ € $ ¥ £ † × ← → ↔ ↑ ± ≠ © ® ™ ‰ «+» ‹+› „+“ „+” ‚+‘ ¡ ¿ …</charinsert> –\n<charinsert>&amp;nbsp; &nbsp; [[Category:+]] #REDIRECT[[+]] {{msg-mw|+|notext=1}} &#33;!FUZZY!! ~~~~  &lt;nowiki>+</nowiki></charinsert>\n<charinsert>ڈ ڑ ٹ </charinsert>\n<charinsert>ټ څ ځ ډ ړ ږ ښ ڼ ؤ ي ې ۍ ئ </charinsert>\n<charinsert>{{{+}}} {{+}} {{subst:+}} <noinclude>+</noinclude></charinsert>\n<charinsert>&lt;!--&nbsp;+&nbsp;--> &lt;br&nbsp;/></charinsert>\n</p></div>",
        "edittools-upload": "-",
        "searchdisabled": "{{SITENAME}} no keyepel de cıgerayiş muweqqet bıryayo. no benatê de şıma pê Google eşkeni zerreyê {{SITENAME}} de cıgerayiş bıkeri.",
        "search-error": "Cıgeyrayış de yew xeta emê meydan: $1",
        "preferences": "Tercihi",
-       "mypreferences": "Tercihi",
+       "mypreferences": "Weçinıtışi",
        "prefs-edits": "Amarê vurnayışan:",
        "prefsnologintext2": "Kerem ke, seba vurnayışê tercihanê xo cı kewe.",
        "prefs-skin": "Çerme",
        "prefs-reset-intro": "ena pele de şıma tercihanê xo şenê bıçarnê be tercihanê keyepelê ke verê coy eyar biy.\nNa game tepeya nêerziyena.",
        "prefs-emailconfirm-label": "Tesdiqiya E-posta:",
        "youremail": "E-Mail (mecbur niyo) *:",
-       "username": "{{GENDER:$1|Nameyê karberi}}:",
+       "username": "{{GENDER:$1|Namey karberi}}:",
        "prefs-memberingroups": "{{GENDER:$2|Ezayê}} {{PLURAL:$1|grube|gruban}}:",
        "prefs-memberingroups-type": "$1",
        "prefs-registration": "Wextê qeydbiyayışi",
        "grouppage-autoconfirmed": "{{ns:project}}:Karberê ke otomatikmen biyê araşt",
        "grouppage-bot": "{{ns:project}}:Boti",
        "grouppage-sysop": "{{ns:project}}:İdarekeri",
-       "grouppage-bureaucrat": "{{ns:project}}:Buroqrati",
+       "grouppage-bureaucrat": "{{ns:project}}:Burokrati",
        "grouppage-suppress": "{{ns:project}}:Teftişkar",
        "right-read": "Pera bıwané",
        "right-edit": "Pele bıvurne",
        "nchanges": "$1 {{PLURAL:$1|vurnayış|vurnayışi}}",
        "enhancedrc-since-last-visit": "$1 {{PLURAL:$1|ziyaretê peyêni ra nata}}",
        "enhancedrc-history": "tarix",
-       "recentchanges": "Vuriyayışê peyêni",
+       "recentchanges": "Vurnayışê peyêni",
        "recentchanges-legend": "Tercihê vurnayışanê peyênan",
-       "recentchanges-summary": "Wiki sero vurriyayışê peyêni asenê.",
+       "recentchanges-summary": "Wiki sero vurnayışê peyêni asenê.",
        "recentchanges-noresult": "Goreyê kriteranê kıfşkerdeyan ra qet yew vurnayış nêvêniya.",
        "recentchanges-feed-description": "Ena feed dı vurnayişanê tewr peniyan teqip bık.",
        "recentchanges-label-newpage": "Enê vurnayışi yew pela newiye vıraşta.",
        "rcshowhideliu": "karberanê qeydina $1",
        "rcshowhideliu-show": "Bımocne",
        "rcshowhideliu-hide": "Bınımne",
-       "rcshowhideanons": "karberanê bênameyan $1",
+       "rcshowhideanons": "karberê bênamey $1",
        "rcshowhideanons-show": "Bımocne",
        "rcshowhideanons-hide": "Bınımne",
        "rcshowhidepatr": "$1 vurnayışê ke dewriya geyrayê",
        "recentchangeslinked-toolbox": "Vurnayışê elaqeyıni",
        "recentchangeslinked-title": "Heqa \"$1\" de vurnayışi",
        "recentchangeslinked-summary": "Lista cêrêne, pela bêlikerdiye rê (ya zi karberanê kategoriya bêlikerdiye rê) pelanê gırêdayoğan de lista de vurnayışê peyênana.\n[[Special:Watchlist|Lista şımaya seyrkedışi de]] peli be nuşteyo '''qolınd''' bêli kerdê.",
-       "recentchangeslinked-page": "Nameyê pele:",
+       "recentchangeslinked-page": "Namey pele:",
        "recentchangeslinked-to": "Heruna pela ke yena dayene, vurnayışanê pelanê ke daye ra gırêdayiyê inan bımocne",
        "recentchanges-page-added-to-category": "[[:$1]] kerd kategoriye miyan",
        "recentchanges-page-removed-from-category": "[[:$1]] kategoriye ra vet",
        "imagelinks": "Gurenayışê dosya",
        "linkstoimage": "Ena {{PLURAL:$1|pela|$1 pela}} gıreye ena dosya:",
        "linkstoimage-more": "$1 ra ziyed {{PLURAL:$1|pel|pel}} re gırey dano.\nlisteya ke ha ver a têna na {{PLURAL:$1|dosyaya ewwili|dosyaya $1 ewwili}} mocnena.\n[[Special:WhatLinksHere/$2|pêroyê liste]] mevcud o.",
-       "nolinkstoimage": "Pelanê ser ena dosyayê link biyê çin o.",
+       "nolinkstoimage": "Pele çıniya ke ena dosya ra bestiyena.",
        "morelinkstoimage": "[[Special:WhatLinksHere/$1|Linkanê zafyerî]] ena pele ra link biyo bivîne.",
        "linkstoimage-redirect": "$1 (Dosya raçarnayış) $2",
        "duplicatesoffile": "a {{PLURAL:$1|dosya|$1 dosya}}, kopyayê na dosyayi ([[Special:FileDuplicateSearch/$2|teferruati]]):",
        "unusedtemplateswlh": "linkanê binî",
        "randompage": "Pela raştameyiye",
        "randompage-nopages": "Na {{PLURAL:$2|heruna namey|heruna nameyan}} de nê peli çıniyê: $1.",
-       "randomincategory": "Kategori ra raşt amıyayi perr",
+       "randomincategory": "Ena kategoriye dı pela raştameye",
        "randomincategory-invalidcategory": "\"$1\" yew nameyê kategoriya vêrdiye niyo.",
        "randomincategory-nopages": "Kategori da [[:Category:$1|$1]] de qet  per çıniya.",
        "randomincategory-category": "Kategoriye:",
        "lonelypagestext": "Ena pelî link nibiyê ya zi pelanê binî {{SITENAME}} de transclude biy.",
        "uncategorizedpages": "Pelê ke kategorize nêbiyê",
        "uncategorizedcategories": "Kategoriyê ke kategorize nêbiyê",
-       "uncategorizedimages": "Dosye yê  bêkategori",
+       "uncategorizedimages": "Dosyeyê kategorinêbiyay.",
        "uncategorizedtemplates": "Şablonê ke bêkategoriyê",
-       "unusedcategories": "Kategoriyê ke nêkarênê",
+       "unusedcategories": "Kategoriyê ke nêguriyay",
        "unusedimages": "Dosyeyê ke nêguriyenê",
        "wantedcategories": "Kategoriyê ke waziyayê",
        "wantedpages": "Pelê ke waziyayê",
        "prefixindex-namespace": "Peleyê Veroleyıni ($1 cay nami)",
        "prefixindex-submit": "Bımocne",
        "prefixindex-strip": "Listeya réz bıyayışi",
-       "shortpages": "Perrê kılmeki",
-       "longpages": "Perrê  dergeki",
+       "shortpages": "Pelê kılmi",
+       "longpages": "Pelê dergi",
        "deadendpages": "Perrê kı perranê binan rê grey c çıni yo",
        "deadendpagestext": "Ena pelan ke {{SITENAME}} de zerrî ey de link çini yo.",
        "protectedpages": "Pellê kı pawıyayeyè",
        "newpages": "Pelê newey",
        "newpages-submit": "Bımocne",
        "newpages-username": "Nameyê karberi:",
-       "ancientpages": "Perrê kı rewnayo kı nêvuriya yê",
+       "ancientpages": "Tewr pelê kıhani",
        "move": "Bıkırışe",
        "movethispage": "Ena pele bıkırışe",
        "unusedimagestext": "Enê dosyey estê, feqet zerrey yew pele de wedardey niyê.\nXo vira mekerê ke, sıteyê webiê bini şenê direkt ebe URLi yew dosya ra gırê bê, u wına şenê verba gurênayışo feal de tiya hewna lista bê.",
        "apisandbox-sending-request": "API waştış rışêno...",
        "apisandbox-request-url-label": "URL waştış:",
        "apisandbox-request-time": "Demê waştışi: {{PLURAL:$1|$1 ms}}",
-       "booksources": "Çıme kıtabi",
+       "booksources": "Çımey kıtabi",
        "booksources-search-legend": "Seba çımeyanê kıtaban cı geyre",
        "booksources-isbn": "ISBN:",
        "booksources-search": "Cı geyre",
        "checkbox-all": "Pêro",
        "checkbox-none": "Temam",
        "checkbox-invert": "Rageyre",
-       "allpages": "Pelli pêro",
+       "allpages": "Pêro peli",
        "nextpage": "Pela badê cû ($1)",
        "prevpage": "Pela verêne ($1)",
        "allpagesfrom": "Pera liste kerdışi bıasne:",
        "removedwatchtext": "Ena pela \"[[:$1]]\" biya wedariya [[Special:Watchlist|listeyê seyr-kerdışi şıma]].",
        "removedwatchtext-short": "Pera $1`i listeya seyran de şıma ra wedari yê",
        "watch": "Seyr ke",
-       "watchthispage": "Peller seyr kı",
+       "watchthispage": "Bewnı ena pele",
        "unwatch": "Teqib meke",
        "unwatchthispage": "temaşa kerdışê peli vındarn.",
        "notanarticle": "mebhesê peli niyo",
        "sp-contributions-hideminor": "Vurriyayışanê werdiyan bınımne",
        "sp-contributions-submit": "Cı geyre",
        "whatlinkshere": "Linkê tedeestey",
-       "whatlinkshere-title": "Per da \"$1\" rê perê ke gre danê",
+       "whatlinkshere-title": "Pelê ke \"$1\" ra bestiyenê",
        "whatlinkshere-page": "Pele:",
        "linkshere": "Ena peleyan grey biya '''[[:$1]]''':",
        "nolinkshere": "Per da '''[[:$1]]''' rê pera ke gıre dana çıniya.",
        "tooltip-t-emailuser": "Ena karber ri yew email bırış",
        "tooltip-t-upload": "Dosyeyan bar ke",
        "tooltip-t-specialpages": "Yew lista pelanê xasanê pêroyinan",
-       "tooltip-t-print": "Hewl versiyona ploğnayışa na perer",
+       "tooltip-t-print": "Versiyonê peleyo ke şeno çap bıkeriyo.",
        "tooltip-t-permalink": "Gırêyo daimi be ena versiyonê pele",
        "tooltip-ca-nstab-main": "Pela zerreki bıvêne",
        "tooltip-ca-nstab-user": "Pela karberi bıvêne",
        "exif-primarychromaticities": "Kromaticitiyê eveli",
        "exif-ycbcrcoefficients": "Cayê rengi yê transformasyon metriksê koefişinti",
        "exif-referenceblackwhite": "Çiftyê siya u sipe değerê referansi",
-       "exif-datetime": "Zeman u tarixê vurnayişê dosyayi",
+       "exif-datetime": "Zeman u tarixê vurnayışê dosya",
        "exif-imagedescription": "Serê resimi",
        "exif-make": "Vıraştoğê kamera",
        "exif-model": "Modelê kamera",
-       "exif-software": "Software ke hebitiyeno",
+       "exif-software": "Softwaro ke xebıtiyeno",
        "exif-artist": "Nuştoğ",
        "exif-copyright": "Wahirê copyrighti",
        "exif-exifversion": "Versiyonê Exif",
        "exif-usercomment": "Mışewreyê karberi",
        "exif-relatedsoundfile": "Derhekê dosya yê vengi",
        "exif-datetimeoriginal": "Demê afernayışê dayeyo sıfteyıni",
-       "exif-datetimedigitized": "Zeman û tarixê dicitalkerdışi",
+       "exif-datetimedigitized": "Zeman u tarixê dijitalkerdışi",
        "exif-subsectime": "ZemanTarix saniyeyibini",
        "exif-subsectimeoriginal": "ZemanTarixOricinal saniyeyibini",
        "exif-subsectimedigitized": "ZemanTarixDicital saniyeyibini",
        "version": "Versiyon",
        "version-extensions": "Ekstensiyonî ke ronaye",
        "version-skins": "Bar kerde bejni",
-       "version-specialpages": "Pellê xısusiy",
+       "version-specialpages": "Pelê hısusiy",
        "version-parserhooks": "Çengelê Parserî",
        "version-variables": "Vurnayeyî",
        "version-antispam": "Spam vındarnayış",
        "fileduplicatesearch-result-1": "Dosyayê ''$1î'' de hem-kopya çini yo.",
        "fileduplicatesearch-result-n": "Dosyayê ''$1î'' de {{PLURAL:$2|1 hem-kopya|$2 hem-kopyayî'}} esto.",
        "fileduplicatesearch-noresults": "Ebe namey \"$1\" ra dosya nêdiyayê.",
-       "specialpages": "Perrê Hısusi",
+       "specialpages": "Pelê hısusiy",
        "specialpages-note-top": "Kıtabek",
        "specialpages-note": "* Pelê xasê normali.\n* <span class=\"mw-specialpagerestricted\">Pelê xasê nımıtey.</span>",
        "specialpages-group-maintenance": "Raporê pawıtışi",
        "specialpages-group-login": "Dekew / hesab vıraz",
        "specialpages-group-changes": "Vurnayışê peyêni û qeydi",
        "specialpages-group-media": "Raporê medya û barkerdışi",
-       "specialpages-group-users": "Karberi u heqê ",
+       "specialpages-group-users": "Karberi u heqê inan",
        "specialpages-group-highuse": "Peleyê ke vêşi karênê",
        "specialpages-group-pages": "Listeyê pelan",
        "specialpages-group-pagetools": "Haletê pelan",
        "tags-create-reason": "Sebeb:",
        "tags-create-submit": "Vıraze",
        "tags-edit-reason": "Sebeb:",
-       "comparepages": "Perra pêver kı",
+       "comparepages": "Pelan têversanê",
        "compare-page1": "Pele 1",
        "compare-page2": "Pele 2",
        "compare-rev1": "Revizyonê 1i",
        "limitreport-templateargumentsize-value": "$1/$2 {{PLURAL:$2|bayt|bayti}}",
        "limitreport-expansiondepth": "Tewr veşi herayina dergbiyayışi",
        "limitreport-expensivefunctioncount": "Amoriya fonksiyonde vay agozni",
-       "expandtemplates": "Å\9fablona hera kı",
+       "expandtemplates": "Å\9eablonan hera kı",
        "expand_templates_intro": "Na pela xususi metın geno u şablonê ke tedeyê reyna reyna hêra keno.\nU hem zi nê fonksiyonan hêra keno\n<nowiki>{{</nowiki>#language:…}}</code>, u zey nê parametreyan\n<nowiki>{{</nowiki>CURRENTDAY}}</code>\nEneri Medya wiki sera xo keno.",
        "expand_templates_title": "Sernameyê weziyeti, misal qandê {{FULLPAGENAME}}.:",
        "expand_templates_input": "sernameyê cıkewtışi:",
        "mw-widgets-dateinput-placeholder-day": "SSSS-AA-RR",
        "mw-widgets-dateinput-placeholder-month": "SSSS-AA",
        "mw-widgets-titleinput-description-redirect": "berd be $1",
-       "randomrootpage": "Raştamaye perra çımey",
+       "randomrootpage": "Pela raştmameya rıçıkıne",
        "log-action-filter-newusers": "Babetê hesabvıraştışi:",
        "changecredentials": "Malumatanê karberi bıvurnê",
-       "removecredentials": "Kamiyer wedarne",
+       "removecredentials": "Kamiye wedarne",
        "removecredentials-submit": "Kamiyer wedarne"
 }
index 733f003..2004e0f 100644 (file)
        "action-upload_by_url": "upload this file from a URL",
        "action-writeapi": "use the write API",
        "action-delete": "delete this page",
-       "action-deleterevision": "delete this revision",
-       "action-deletedhistory": "view this page's deleted history",
+       "action-deleterevision": "delete revisions",
+       "action-deletelogentry": "delete log entries",
+       "action-deletedhistory": "view a page's deleted history",
+       "action-deletedtext": "view deleted revision text",
        "action-browsearchive": "search deleted pages",
-       "action-undelete": "undelete this page",
-       "action-suppressrevision": "review and restore this hidden revision",
+       "action-undelete": "undelete pages",
+       "action-suppressrevision": "review and restore hidden revisions",
        "action-suppressionlog": "view this private log",
        "action-block": "block this user from editing",
        "action-protect": "change protection levels for this page",
        "action-userrights-interwiki": "edit user rights of users on other wikis",
        "action-siteadmin": "lock or unlock the database",
        "action-sendemail": "send emails",
+       "action-editmyoptions": "edit your preferences",
        "action-editmywatchlist": "edit your watchlist",
        "action-viewmywatchlist": "view your watchlist",
        "action-viewmyprivateinfo": "view your private information",
        "usercssispublic": "Please note: CSS subpages should not contain confidential data as they are viewable by other users.",
        "restrictionsfield-badip": "Invalid IP address or range: $1",
        "restrictionsfield-label": "Allowed IP ranges:",
-       "restrictionsfield-help": "One IP address or CIDR range per line. To enable everything, use<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "One IP address or CIDR range per line. To enable everything, use<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "revid": "r$1",
+       "pageid": "page ID $1"
 }
index 2e53ce5..9933fed 100644 (file)
        "mainpage-nstab": "Esileht",
        "nosuchaction": "Sellist toimingut pole.",
        "nosuchactiontext": "Viki ei tunne internetiaadressile vastavat tegevust.\nVõimalik, et sa sisestasid aadressi valesti või kasutasid vigast linki.\nSamuti ei ole välistatud, et tarkvaras, mida {{SITENAME}} kasutatab, on viga.",
-       "nosuchspecialpage": "Sellist erilehekülge pole.",
+       "nosuchspecialpage": "Sellist erilehekülge pole",
        "nospecialpagetext": "<strong>Viki ei tunne erilehekülge, mille poole pöördusid.</strong>\n\nKäibel olevad erileheküljed on loetletud leheküljel [[Special:SpecialPages|{{int:specialpages}}]].",
        "error": "Viga",
        "databaseerror": "Andmebaasi viga",
        "virus-scanfailed": "skaneerimine ebaõnnestus (veakood $1)",
        "virus-unknownscanner": "tundmatu viirusetõrje:",
        "logouttext": "<strong>Oled nüüd välja loginud.</strong>\n\nPane tähele, et seni, kuni sa pole veebilehitseja puhvrit tühjendanud, võidakse mõni lehekülg endiselt kuvada nii nagu oleksid ikka sisse logitud.",
+       "cannotlogoutnow-title": "Praegu ei saa välja logida",
+       "cannotlogoutnow-text": "Väljalogimine pole võimalik, kui kasutad $1.",
        "welcomeuser": "Tere tulemast, $1!",
        "welcomecreation-msg": "Sinu konto on loodud.\nÄra unusta seada oma {{GRAMMAR:genitive|{{SITENAME}}}} [[Special:Preferences|eelistusi]].",
        "yourname": "Kasutajanimi:",
        "createacct-yourpasswordagain-ph": "Sisesta uuesti parool",
        "userlogin-remembermypassword": "Jää sisseloginuks",
        "userlogin-signwithsecure": "Kasuta turvalist ühendust",
+       "cannotlogin-title": "Ei saa sisse logida",
+       "cannotlogin-text": "Sisselogimine pole võimalik.",
+       "cannotloginnow-title": "Praegu ei saa sisse logida",
+       "cannotloginnow-text": "Sisselogimine pole võimalik, kui kasutad $1.",
+       "cannotcreateaccount-title": "Ei saa kontosid luua",
+       "cannotcreateaccount-text": "Kontode käsitsi loomine pole selles vikis lubatud.",
        "yourdomainname": "Sinu domeen:",
        "password-change-forbidden": "Selles vikis ei saa paroole muuta.",
        "externaldberror": "Esines autentimistõrge või sul pole õigust konto andmeid muuta.",
        "emailccsubject": "Koopia sinu sõnumist kasutajale $1: $2",
        "emailsent": "E-kiri saadetud",
        "emailsenttext": "Sinu teade on e-kirjaga saadetud.",
-       "emailuserfooter": "Selle e-kirja saatis $1 {{GRAMMAR:elative|{{SITENAME}}}} kasutajale $2 toimingu \"{{int:emailuser}}\" abil.",
+       "emailuserfooter": "Selle e-kirja saatis $1 {{GRAMMAR:elative|{{SITENAME}}}} kasutajale $2 toimingu \"{{int:emailuser}}\" abil. Sinu kiri saadetakse otse algse kirja saatjale, mistõttu saab ta sinu e-posti aadressi teada.",
        "usermessage-summary": "Jätan süsteemiteate.",
        "usermessage-editor": "Süsteemiteadete edastaja",
        "watchlist": "Jälgimisloend",
        "mw-widgets-dateinput-placeholder-month": "AAAA-KK",
        "mw-widgets-titleinput-description-new-page": "lehekülge pole veel",
        "mw-widgets-titleinput-description-redirect": "ümbersuunamine leheküljele \"$1\"",
+       "mw-widgets-categoryselector-add-category-placeholder": "Lisa kategooria...",
+       "sessionprovider-generic": "klassi $1 seansse",
+       "sessionprovider-mediawiki-session-cookiesessionprovider": "küpsisepõhiseid seansse",
        "randomrootpage": "Juhuslik juurlehekülg",
        "log-action-filter-block": "Blokeeringu tüüp:",
        "log-action-filter-contentmodel": "Sisumudeli muudatuse tüüp:",
index 4a6080b..27c22a5 100644 (file)
        "tags-edit": "ویرایش",
        "tags-delete": "حذف",
        "tags-activate": "فعال‌سازی",
-       "tags-deactivate": "غیرفعال کردن/إکار کةتن",
+       "tags-deactivate": "غیرفعال کردن",
        "tags-hitcount": "$1 {{PLURAL:$1|تغییر|تغییر}}",
        "tags-manage-no-permission": "شما اجازه مدیریت تغییر تگ‌ها را ندارید.",
        "tags-manage-blocked": "امکان تغییر برچسب‌ها را در زمان بسته‌بودن {{GENDER:$1|ندارید}}",
index c3716c6..1a5a9a9 100644 (file)
        "htmlform-user-not-exists": "Käyttäjää <strong>$1</strong> ei ole olemassa.",
        "htmlform-user-not-valid": "<strong>$1</strong> ei ole kelvollinen käyttäjänimi.",
        "logentry-delete-delete": "$1 {{GENDER:$2|poisti}} sivun $3",
+       "logentry-delete-delete_redir": "$1 {{GENDER:$2|poisti}} ohjaussivun $3 korvaamalla",
        "logentry-delete-restore": "$1 {{GENDER:$2|palautti}} sivun $3",
        "logentry-delete-event": "$1 {{GENDER:$2|muutti}} {{PLURAL:$5|lokitapahtuman|$5 lokitapahtuman}} näkyvyyttä kohteessa $3: $4",
        "logentry-delete-revision": "$1 {{GENDER:$2|muutti}} {{PLURAL:$5|version|$5 version}} näkyvyyttä sivulla $3: $4",
index 1ca20e5..1b352f2 100644 (file)
        "subject-preview": "Aperçu du sujet :",
        "previewerrortext": "Une erreur s’est produite lors de la tentative de prévisualisation de vos modifications.",
        "blockedtitle": "L’utilisateur est bloqué.",
-       "blockedtext": "'''Votre compte utilisateur ou votre adresse IP a été bloqué.'''\n\nLe blocage a été effectué par $1.\nLa raison invoquée est la suivante : ''$2''.\n\n* Début du blocage : $8\n* Expiration du blocage : $6\n* Compte bloqué : $7.\n\nVous pouvez contacter $1 ou un autre [[{{MediaWiki:Grouppage-sysop}}|administrateur]] pour en discuter.\nVous ne pouvez utiliser la fonction « {{int:emailuser}} » que si une adresse de courriel valide est spécifiée dans vos [[Special:Preferences|préférences]] et que si cette fonctionnalité n’a pas été bloquée.\nVotre adresse IP actuelle est $3 et votre identifiant de blocage est $5.\nVeuillez préciser ces indications dans toutes les requêtes que vous ferez.",
+       "blockedtext": "<strong>Votre compte utilisateur ou votre adresse IP a été bloqué.</strong>\n\nLe blocage a été effectué par $1.\nLa raison invoquée est la suivante : <em>$2</em>.\n\n* Début du blocage : $8\n* Expiration du blocage : $6\n* Compte bloqué : $7.\n\nVous pouvez contacter $1 ou un autre [[{{MediaWiki:Grouppage-sysop}}|administrateur]] pour en discuter.\nVous ne pouvez utiliser la fonction « {{int:emailuser}} » que si une adresse de courriel valide est spécifiée dans vos [[Special:Preferences|préférences]] et que si cette fonctionnalité n’a pas été bloquée.\nVotre adresse IP actuelle est $3 et votre identifiant de blocage est $5.\nVeuillez préciser ces indications dans toutes les requêtes que vous ferez.",
        "autoblockedtext": "Votre adresse IP a été bloquée automatiquement car elle a été utilisée par un autre utilisateur, lui-même bloqué par $1.\nLa raison invoquée est :\n\n:<em>$2:</em>\n\n* Début du blocage : $8\n* Expiration du blocage : $6\n* Compte bloqué : $7\n\nVous pouvez contacter $1 ou l’un des autres [[{{MediaWiki:Grouppage-sysop}}|administrateurs]] pour discuter de ce blocage.\n\nNotez que vous ne pourrez utiliser la fonctionnalité d’envoi de courriel que si vous avez une adresse de courriel validée dans vos [[Special:Preferences|préférences]] et que cette fonctionnalité n’a pas été désactivée.\n\nVotre adresse IP actuelle est $3, et le numéro de blocage est $5.\nVeuillez préciser ces indications dans toutes les requêtes que vous ferez.",
        "blockednoreason": "aucune raison donnée",
        "whitelistedittext": "Vous devez vous $1 pour avoir la permission de modifier le contenu.",
        "userrights-user-editname": "Entrez un nom d'utilisateur :",
        "editusergroup": "Charger des groupes d’utilisateurs",
        "editinguser": "Modification des droits de l’{{GENDER:$1|utilisateur|utilisatrice}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "Affichage des droits utilisateur de {{GENDER:$1|l’utilisateur|l’utilisatrice}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Modifier les groupes de l'utilisateur",
+       "userrights-viewusergroup": "Afficher les groupes d'utilisateurs",
        "saveusergroups": "Enregistrer les groupes de l’{{GENDER:$1|utilisateur|utilisatrice}}",
        "userrights-groupsmember": "Membre de :",
        "userrights-groupsmember-auto": "Membre implicite de :",
        "action-upload_by_url": "importer ce fichier à partir d'une adresse URL",
        "action-writeapi": "utiliser l‘API d'écriture",
        "action-delete": "supprimer cette page",
-       "action-deleterevision": "supprimer cette version",
-       "action-deletedhistory": "voir l’historique supprimé de cette page",
+       "action-deleterevision": "supprimer les révisions",
+       "action-deletelogentry": "supprimer les entrées de la trace",
+       "action-deletedhistory": "voir l’historique supprimé d’une page",
+       "action-deletedtext": "Afficher le texte de la révision supprimée",
        "action-browsearchive": "rechercher des pages supprimées",
-       "action-undelete": "restaurer cette page",
-       "action-suppressrevision": "visionner et rétablir cette version supprimée",
+       "action-undelete": "restaurer des pages",
+       "action-suppressrevision": "visionner et rétablir des révisions supprimées",
        "action-suppressionlog": "voir ce journal privé",
        "action-block": "bloquer en écriture cet utilisateur",
        "action-protect": "modifier les niveaux de protection pour cette page",
        "action-userrights-interwiki": "modifier les droits des utilisateurs sur d'autres wikis",
        "action-siteadmin": "verrouiller ou déverrouiller la base de données",
        "action-sendemail": "envoyer des courriels",
+       "action-editmyoptions": "modifier vos préférences",
        "action-editmywatchlist": "modifier votre liste de suivi",
        "action-viewmywatchlist": "afficher votre liste de suivi",
        "action-viewmyprivateinfo": "voir vos informations personnelles",
        "uploaded-setting-event-handler-svg": "Positionner les attributs du gestionnaire d’événements n'est pas possbile, <code>&lt;$1 $2=\"$3\"&gt;</code> trouvé dans le fichier SVG téléchargé.",
        "uploaded-setting-href-svg": "L’utilisation de la balise « set » pour ajouter un attribut « href » à l’élément parent est interdite.",
        "uploaded-wrong-setting-svg": "L’utilisation de la balise « set » pour ajouter une cible distante/données/script à un attribut quelconque est interdite. <code>&lt;set to=\"$1\"&gt;</code> a été trouvé dans le fichier SVG téléchargé.",
-       "uploaded-setting-handler-svg": "Les SVG qui positionnent l’attribut « handler » avec distant/données/script sont interdits. <code>$1=\"$2\"</code> a été trouvé dans le fichier SVG téléchargé.",
+       "uploaded-setting-handler-svg": "Les SVG qui positionnent l’attribut « handler » avec distant/données/script sont bloqués. <code>$1=\"$2\"</code> a été trouvé dans le fichier SVG téléchargé.",
        "uploaded-remote-url-svg": "Les SVG qui positionnent un attribut de style avec une URL distante sont bloqués. <code>$1=\"$2\"</code> trouvé dans le fichier SVG téléchargé.",
        "uploaded-image-filter-svg": "Filtre d’image avec URL trouvé : <code>&lt;$1 $2=\"$3\"&gt;</code> dans le fichier SVG téléchargé.",
        "uploadscriptednamespace": "Ce fichier SVG contient un espace de noms '$1' non autorisé.",
        "feedback-external-bug-report-button": "Signaler un bogue technique",
        "feedback-dialog-title": "Soumettre un commentaire",
        "feedback-dialog-intro": "Vous pouvez utiliser le simple formulaire ci-dessous pour faire parvenir vos commentaires. Votre commentaire sera ajouté à la page « $1 », ainsi que votre nom d’utilisateur.",
-       "feedback-error1": "Erreur : Résultat de l'IPA non reconnu",
+       "feedback-error1": "Erreur : résultat de l'API non reconnu",
        "feedback-error2": "Erreur : la modification a échoué",
        "feedback-error3": "Erreur : aucune réponse de l'API",
        "feedback-error4": "Erreur : Impossible de publier sous le titre d’avis donné",
        "searchsuggest-search": "Rechercher sur {{SITENAME}}",
        "searchsuggest-containing": "contenant...",
        "api-error-autoblocked": "Votre adresse IP a été bloquée automatiquement, parce qu’elle a été utilisée par un utilisateur bloqué.",
-       "api-error-badaccess-groups": "Vous n'êtes pas autorisé à verser des fichiers sur ce wiki.",
+       "api-error-badaccess-groups": "Vous n'êtes pas autorisé à téléverser des fichiers sur ce wiki.",
        "api-error-badtoken": "Erreur interne : mauvais « jeton ».",
        "api-error-blocked": "Vous avez été bloqué en édition.",
        "api-error-copyuploaddisabled": "Les versements via URL sont désactivés sur ce serveur.",
        "limitreport-expansiondepth": "Plus grande profondeur d’expansion",
        "limitreport-expensivefunctioncount": "Nombre de fonctions d’analyse coûteuses",
        "expandtemplates": "Expansion des modèles",
-       "expand_templates_intro": "Cette page spéciale accepte un texte wiki source et permet de réaliser récursivement l’expansion des modèles qu’il contient.\nElle réalise aussi l’expansion des fonctions du parseur telles que\n<code><nowiki>{{</nowiki>#language:...}}</code> et des variables telles que\n<code><nowiki>{{</nowiki>CURRENTDAY}}</code>.\nEn fait, elle réalise l'expansion de pratiquement tout ce qui est encadré par des doubles accolades.",
+       "expand_templates_intro": "Cette page spéciale accepte un texte wiki source et permet de réaliser récursivement l’expansion de tous les modèles qu’il contient.\nElle réalise aussi l’expansion des fonctions supportées d'analyse telles que\n<code><nowiki>{{</nowiki>#language:...}}</code> et des variables telles que\n<code><nowiki>{{</nowiki>CURRENTDAY}}</code>.\nEn fait, elle réalise l'expansion de pratiquement tout ce qui est encadré par des doubles accolades.",
        "expand_templates_title": "Titre de la page, si le code utilise {{FULLPAGENAME}}, etc. :",
        "expand_templates_input": "Texte wiki source :",
        "expand_templates_output": "Texte wiki obtenu après expansion",
        "usercssispublic": "Veuillez noter: les sous-pages CSS ne doivent pas contenir de données confidentielles parce qu'elles sont visibles des autres utilisateurs.",
        "restrictionsfield-badip": "Adresse IP ou plage non valide : $1",
        "restrictionsfield-label": "Plages IP autorisées :",
-       "restrictionsfield-help": "Une adresse IP ou une plage CIDR par ligne. Pour tout activer, utiliser <br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "Une adresse IP ou une plage CIDR par ligne. Pour tout activer, utiliser <br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "pageid": "ID de page $1"
 }
index 8e286db..eba3cb5 100644 (file)
        "editusergroup": "Cargar os grupos de usuario",
        "editinguser": "Mudando os dereitos {{GENDER:$1|do usuario|da usuaria}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Editar os grupos do usuario",
+       "userrights-viewusergroup": "Consultar os grupos do usuario",
        "saveusergroups": "Gardar os grupos {{GENDER:$1|do usuario|da usuaria}}",
        "userrights-groupsmember": "Membro de:",
        "userrights-groupsmember-auto": "Membro implícito de:",
        "action-upload_by_url": "cargar este ficheiro desde un enderezo URL",
        "action-writeapi": "usar a escritura API",
        "action-delete": "borrar esta páxina",
-       "action-deleterevision": "borrar esta revisión",
-       "action-deletedhistory": "ver o historial borrado desta páxina",
+       "action-deleterevision": "borrar revisións",
+       "action-deletelogentry": "borrar entradas do rexistro",
+       "action-deletedhistory": "ver o historial borrado dunha páxina",
+       "action-deletedtext": "ver o texto dunha revisión borrada",
        "action-browsearchive": "procurar páxinas borradas",
-       "action-undelete": "restaurar esta páxina",
-       "action-suppressrevision": "revisar e restaurar esta revisión agochada",
+       "action-undelete": "restaurar páxinas",
+       "action-suppressrevision": "revisar e restaurar revisións agochadas",
        "action-suppressionlog": "ver este rexistro privado",
        "action-block": "bloquear o usuario fronte á edición",
        "action-protect": "cambiar o nivel de protección desta páxina",
        "action-userrights-interwiki": "editar os permisos de usuario dos usuarios doutros wikis",
        "action-siteadmin": "bloquear ou desbloquear a base de datos",
        "action-sendemail": "enviar correos electrónicos",
+       "action-editmyoptions": "Editar as súas preferencias",
        "action-editmywatchlist": "editar a súa lista de vixilancia",
        "action-viewmywatchlist": "ver a súa lista de vixilancia",
        "action-viewmyprivateinfo": "ver a súa información privada",
        "mw-widgets-dateinput-no-date": "Non se seleccionou ningunha data",
        "mw-widgets-dateinput-placeholder-day": "AAAA-MM-DD",
        "mw-widgets-dateinput-placeholder-month": "AAAA-MM",
+       "mw-widgets-mediasearch-input-placeholder": "Procurar ficheiros multimedia",
        "mw-widgets-mediasearch-noresults": "Non se atopou ningún resultado.",
        "mw-widgets-titleinput-description-new-page": "a páxina aínda non existe",
        "mw-widgets-titleinput-description-redirect": "redirección cara a $1",
        "usercssispublic": "Lembre: As subpáxinas CSS non deberían conter datos confidenciais porque outros usuarios poden velos.",
        "restrictionsfield-badip": "Enderezo IP ou rango de IP non válido: $1",
        "restrictionsfield-label": "Rangos de IP permitidos:",
-       "restrictionsfield-help": "Un único enderezo IP ou rango CIDR por liña. Para habilitalos todos, utilice<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "Un único enderezo IP ou rango CIDR por liña. Para habilitalos todos, utilice<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "pageid": "identificador de páxina $1"
 }
index 5a55799..bf53e1c 100644 (file)
        "userrights-user-editname": "שם משתמש:",
        "editusergroup": "טעינת קבוצות המשתמש",
        "editinguser": "שינוי ההרשאות של {{GENDER:$1|המשתמש|המשתמשת}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "צפייה בהרשאות של {{GENDER:$1|המשתמש|המשתמשת}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "עריכת קבוצות משתמש",
+       "userrights-viewusergroup": "צפייה בקבוצות משתמש",
        "saveusergroups": "שמירת הקבוצות של ה{{GENDER:$1|משתמש|משתמשת}}",
        "userrights-groupsmember": "{{GENDER:$2|חבר|חברה}} ב{{PLURAL:$1|קבוצה|קבוצות}}:",
        "userrights-groupsmember-auto": "{{GENDER:$2|חבר|חברה}} אוטומטית ב{{PLURAL:$1|קבוצה|קבוצות}}:",
        "action-upload_by_url": "להעלות קובץ זה מכתובת URL",
        "action-writeapi": "להשתמש ב־API לשינוי דפים",
        "action-delete": "למחוק דף זה",
-       "action-deleterevision": "למחוק גרסה זו",
-       "action-deletedhistory": "לצפות בהיסטוריה המחוקה של דפים",
+       "action-deleterevision": "למחוק גרסאות",
+       "action-deletelogentry": "למחוק פריטי יומן",
+       "action-deletedhistory": "לצפות בהיסטוריה מחוקה של דף",
+       "action-deletedtext": "לצפות בטקסט של גרסה מחוקה",
        "action-browsearchive": "לחפש דפים מחוקים",
-       "action-undelete": "×\9cש×\97×\96ר ×\93×£ ×\96×\94",
-       "action-suppressrevision": "×\9c×\91×\93×\95ק ×\95×\9cש×\97×\96ר ×\92רס×\94 ×\9e×\95סתרת ×\96×\95",
+       "action-undelete": "×\9cש×\97×\96ר ×\93פ×\99×\9d",
+       "action-suppressrevision": "×\9cסק×\95ר ×\95×\9cש×\97×\96ר ×\92רס×\90×\95ת ×\9e×\95סתר×\95ת",
        "action-suppressionlog": "לצפות ביומן הפרטי הזה",
        "action-block": "לחסום משתמשים מעריכה",
        "action-protect": "לשנות את רמת ההגנה של דף זה",
        "action-userrights-interwiki": "לשנות הרשאות של משתמשים באתרי ויקי אחרים",
        "action-siteadmin": "לנעול או לבטל את הנעילה של בסיס הנתונים",
        "action-sendemail": "לשלוח דואר אלקטרוני למשתמשים",
+       "action-editmyoptions": "לערוך את ההעדפות {{GENDER:|שלך|שלך|שלכם}}",
        "action-editmywatchlist": "לערוך את רשימת המעקב {{GENDER:|שלך|שלך|שלכם}}",
        "action-viewmywatchlist": "לצפות ברשימת המעקב {{GENDER:|שלך|שלך|שלכם}}",
        "action-viewmyprivateinfo": "לצפות במידע הפרטי {{GENDER:|שלך|שלך|שלכם}}",
        "usercssispublic": "שימו לב: משתמשים אחרים יכולים לצפות בדפי ה־CSS שלכם, ולכן אין לכלול בהם מידע סודי.",
        "restrictionsfield-badip": "כתובת או טווח כתובות IP בלתי תקין: $1",
        "restrictionsfield-label": "טווחי כתובות IP מותרים:",
-       "restrictionsfield-help": "כתובת IP אחת או טווח CIDR אחד בשורה. כדי לאפשר את הכול, ניתן להשתמש ב:<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "כתובת IP אחת או טווח CIDR אחד בשורה. כדי לאפשר את הכול, ניתן להשתמש ב:<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "revid": "גרסה $1",
+       "pageid": "מזהה דף $1"
 }
index de0baab..999d03b 100644 (file)
        "rollback-success": "uklonjeno uređivanje {{GENDER:$1|suradnika|suradnice}} $1\nvraćeno na posljednju inačicu {{GENDER:$2|suradnika|suradnice}} $2.",
        "sessionfailure-title": "Prekid sesije",
        "sessionfailure": "Uočili smo problem s Vašom prijavom. Zadnja naredba nije izvršena kako bi se izbjegla zloupotreba. Molimo Vas da se u pregledniku vratite natrag na prethodnu stranicu, ponovno je učitate i zatim pokušate opet.",
-       "changecontentmodel": "Promijeni model sadržaja stranice",
+       "changecontentmodel": "Promjena modela sadržaja stranice",
        "changecontentmodel-legend": "Promijeni model sadržaja",
        "changecontentmodel-title-label": "Naziv stranice",
        "changecontentmodel-model-label": "Novi model sadržaja",
        "changecontentmodel-reason-label": "Razlog:",
+       "changecontentmodel-submit": "Promijeni",
        "changecontentmodel-success-title": "Sadržaj modela je promijenjen",
        "protectlogpage": "Evidencija zaštićivanja",
        "protectlogtext": "Ispod je evidencija zaštićivanja i uklanjanja zaštite pojedinih stranica.\nPogledajte [[Special:ProtectedPages|zaštićene stranice]] za popis trenutačno zaštićenih stranica.",
index 6efe0d0..face238 100644 (file)
        "userrights-user-editname": "Entra un nomine de usator:",
        "editusergroup": "Cargar gruppos de usator",
        "editinguser": "Cambia le derectos del {{GENDER:$1|usator}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "Ecce le derectos del {{GENDER:$1|usator}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Modificar gruppos de usatores",
+       "userrights-viewusergroup": "Vider gruppos del usator",
        "saveusergroups": "Salveguardar gruppos de {{GENDER:$1|usator}}",
        "userrights-groupsmember": "Membro de:",
        "userrights-groupsmember-auto": "Membro implicite de:",
        "action-upload_by_url": "incargar iste file ab un adresse URL",
        "action-writeapi": "usar le API pro modificar le wiki",
        "action-delete": "deler iste pagina",
-       "action-deleterevision": "deler iste version",
-       "action-deletedhistory": "vider le historia delite de iste pagina",
+       "action-deleterevision": "deler versiones",
+       "action-deletelogentry": "deler entratas de registro",
+       "action-deletedhistory": "vider le historia delite de un pagina",
+       "action-deletedtext": "vider le texto de un version delite",
        "action-browsearchive": "cercar in paginas delite",
-       "action-undelete": "restaurar iste pagina",
-       "action-suppressrevision": "revider e restaurar iste version celate",
+       "action-undelete": "restaurar paginas",
+       "action-suppressrevision": "revider e restaurar versiones celate",
        "action-suppressionlog": "vider iste registro private",
        "action-block": "blocar iste usator de facer modificationes",
        "action-protect": "cambiar le nivellos de protection pro iste pagina",
        "action-userrights-interwiki": "modificar le derectos de usatores in altere wikis",
        "action-siteadmin": "blocar e disblocar le base de datos",
        "action-sendemail": "inviar e-mail",
+       "action-editmyoptions": "modificar tu preferentias",
        "action-editmywatchlist": "modificar le proprie observatorio",
        "action-viewmywatchlist": "vider le proprie observatorio",
        "action-viewmyprivateinfo": "vider le proprie information private",
        "usercssispublic": "Nota ben: Subpaginas CSS non debe continer datos confidential perque altere usatores pote vider los.",
        "restrictionsfield-badip": "Adresse o intervallo IP non valide: $1",
        "restrictionsfield-label": "Intervallos IP permittite:",
-       "restrictionsfield-help": "Un adresse IP o intervallo CIDR per linea. Pro activar toto, usa<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "Un adresse IP o intervallo CIDR per linea. Pro activar toto, usa<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "pageid": "ID de pagina $1"
 }
index f47a949..998280b 100644 (file)
        "tagline": "Dari {{SITENAME}}",
        "help": "Bantuan",
        "search": "Pencarian",
+       "search-ignored-headings": "# <pre>\n# Judul yang akan diabaikan oleh pencarian.\n# Suntingan ini akan diterapkan setelah halaman dengan judul ini diindeks.\n# Anda bisa memaksakan pengindeksan kembali halaman ini dengan melakukan suntingan kosong (''null edit'')\n# Sintaksisnya adalah seperti berikut:\n#   * Semuanya dari karakter \"#\" ke akhir baris adalah sebuah komentar.\n#   * Setiap baris tak-kosong adalah judul tepat yang akan diabaikan.\nReferensi\nPranala luar\nLihat pula\n #</pre>",
        "searchbutton": "Cari",
        "go": "Tuju ke",
        "searcharticle": "Lanjut",
        "views": "Tampilan",
        "toolbox": "Perkakas",
        "tool-link-userrights": "Simpan kelompok {{GENDER:$1|pengguna}}",
+       "tool-link-userrights-readonly": "Lihat kelompok {{GENDER:$1|pengguna}}",
        "tool-link-emailuser": "Kirim surel ke {{GENDER:$1|pengguna}} ini",
        "userpage": "Lihat halaman pengguna",
        "projectpage": "Lihat halaman proyek",
        "eauthentsent": "Sebuah surel untuk konfirmasi telah dikirim ke alamat surel. Sebelum surel lainnya dikirim ke akun tersebut, Anda harus mengikuti instruksi di dalam surel tersebut, untuk melakukan konfirmasi bahwa alamat tersebut adalah benar kepunyaan Anda.",
        "throttled-mailpassword": "Suatu pengingat kata sandi telah dikirimkan dalam {{PLURAL:$1|$1 jam}} terakhir.\nUntuk menghindari penyalahgunaan, hanya satu kata sandi yang akan dikirimkan setiap {{PLURAL:$1|$1 jam}}.",
        "mailerror": "Kesalahan dalam mengirimkan surel: $1",
-       "acct_creation_throttle_hit": "Pengunjung wiki ini dengan alamat IP yang sama dengan Anda telah membuat {{PLURAL:$1|1 akun|$1 akun}} dalam satu hari terakhir, hingga jumlah maksimum yang diizinkan.\nKarenanya, pengunjung dengan alamat IP ini tidak dapat lagi membuat akun lain untuk sementara.",
+       "acct_creation_throttle_hit": "Pengunjung wiki ini dengan alamat IP yang sama dengan Anda telah membuat {{PLURAL:$1|1 akun|$1 akun}} dalam $2 terakhir, hingga jumlah maksimum yang diizinkan.\nKarenanya, pengunjung dengan alamat IP ini tidak dapat lagi membuat akun lain untuk sementara.",
        "emailauthenticated": "Alamat surel Anda telah dikonfirmasi pada $3, $2.",
        "emailnotauthenticated": "Alamat surel Anda belum dikonfirmasi.\nSebelum dikonfirmasi Anda tidak akan menerima surel dari fitur berikut.",
        "noemailprefs": "Anda harus memasukkan alamat surel di preferensi Anda untuk dapat menggunakan fitur-fitur ini.",
        "botpasswords-label-delete": "Hapus",
        "botpasswords-label-resetpassword": "Setel ulang kata sandi",
        "botpasswords-label-grants": "Akses yang dapat diberikan:",
-       "botpasswords-help-grants": "Tiap izin memberikan akses ke hak-hak pengguna yang telah dimiliki suatu akun pengguna. Lihat [[Special:ListGrants|tabel izin]] untuk informasi lebih lanjut.",
+       "botpasswords-help-grants": "Izin ke akses tertentu telah dimiliki oleh akun pengguna Anda. Mengaktifkan sebuah hak di sini tidak memberikan akses ke akses lain yang tidak dimiliki oleh akun pengguna Anda. Lihat [[Special:ListGrants|daftar hak akses]] untuk informasi selengkapnya.",
        "botpasswords-label-grants-column": "Izin diberikan",
        "botpasswords-bad-appid": "Nama bot \"$1\" tidak valid.",
        "botpasswords-insert-failed": "Gagal menambah nama bot \"$1\". Apakah sudah ditambahkan sebelum ini?",
        "botpasswords-updated-body": "Kata sandi bot \"$1\" dari pengguna \"$2\" berhasil diperbarui.",
        "botpasswords-deleted-title": "Kata sandi bot dihapus",
        "botpasswords-deleted-body": "Kata sandi bot \"$1\" dari pengguna \"$2\" telah dihapus.",
-       "botpasswords-newpassword": "Kata sandi baru untuk masuk log dengan '''$1''' adalah '''$2'''. ''Mohon simpan untuk referensi di kemudian hari.''",
+       "botpasswords-newpassword": "Kata sandi baru untuk masuk log dengan <strong>$1</strong> adalah <strong>$2</strong>. <em>Catatlah kata sandi ini untuk referensi ke depan.</em> <br> (Untuk bot lama yang memerlukan nama masuk log yang sama dengan nama pengguna, dapat menggunakan <strong>$3</strong> sebagai nama pengguna dan <strong>$4</strong> sebagai kata sandi.)",
        "botpasswords-no-provider": "BotPasswordsSessionProvider tidak tersedia.",
        "botpasswords-restriction-failed": "Batasan kata sandi menghalangi masuk log ini.",
        "botpasswords-invalid-name": "Nama pengguna yang diberikan tidak mengandung pemisah kata sandi bot (\"$1\").",
        "invalid-content-data": "Data konten tidak sah",
        "content-not-allowed-here": "Konten \"$1\" tidak diizinkan di halaman [[$2]]",
        "editwarning-warning": "Meninggalkan halaman ini dapat menyebabkan semua perubahan yang belum tersimpan hilang.\nJika Anda telah masuk log, Anda dapat mematikan peringatan ini lewat bagian \"Penyuntingan\" pada halaman preferensi Anda.",
+       "editpage-invalidcontentmodel-title": "Model konten tidak didukung",
+       "editpage-invalidcontentmodel-text": "Model konten \"$1\" tidak didukung.",
        "editpage-notsupportedcontentformat-title": "Format konten tidak didukung",
        "editpage-notsupportedcontentformat-text": "Format konten $1 tidak didukung oleh model konten $2.",
        "content-model-wikitext": "teks wiki",
        "content-model-css": "CSS",
        "content-json-empty-object": "Objek kosong",
        "content-json-empty-array": "Larik kosong",
+       "deprecated-self-close-category": "Halaman yang menggunakan tag HTML tertutup-sendiri tidak sah",
        "duplicate-args-warning": "<strong>Peringatan:</strong> [[:$1]] memanggil [[:$2]] dengan nilai lebih dari satu untuk parameter \"$3\". Hanya nilai terakhir yang tersedia yang akan digunakan.",
        "duplicate-args-category": "Halaman dengan argumen ganda di pemanggilan templat",
        "duplicate-args-category-desc": "Halaman ini berisi pemanggilan templat yang menggunakan argumen ganda, seperti <code><nowiki>{{foo|bar=1|bar=2}}</nowiki></code> atau <code><nowiki>{{foo|bar|1=baz}}</nowiki></code>.",
        "search-external": "Pencarian eksternal",
        "searchdisabled": "Pencarian {{SITENAME}} sementara dimatikan.\nAnda dapat mencari melalui Google untuk sementara waktu.\nPerlu diingat bahwa indeks Google untuk konten {{SITENAME}} mungkin belum mencakup perubahan-perubahan terakhir.",
        "search-error": "Kesalahan terjadi saat mencari: $1",
+       "search-warning": "Peringatan terjadi ketika mencari: $1",
        "preferences": "Preferensi",
        "mypreferences": "Preferensi",
        "prefs-edits": "Jumlah suntingan:",
        "prefs-help-recentchangescount": "Opsi ini berlaku untuk perubahan terbaru, versi terdahulu halaman, dan log.",
        "prefs-help-watchlist-token2": "Ini adalah kunci rahasia (token) ke umpan web dari daftar pantauan Anda.\nSiapa saja yang tahu akan dapat melihat daftar pantauan Anda, jadi jangan dibagikan. Jika diperlukan\n[[Special:ResetTokens|Anda dapat mengatur ulang kunci tersebut]].",
        "savedprefs": "Preferensi Anda telah disimpan",
-       "savedrights": "Hak pengguna {{GENDER:$1|$1}} telah disimpan.",
+       "savedrights": "Kelompok hak pengguna {{GENDER:$1|$1}} telah disimpan.",
        "timezonelegend": "Zona waktu:",
        "localtime": "Waktu setempat:",
        "timezoneuseserverdefault": "Gunakan bawaan wiki ($1)",
        "prefswarning-warning": "Perubahan preferensi anda belum tersimpan. Apabila anda meninggalkan halaman ini tanpa men-klik \"$1\" preferensi anda tidak akan diperbarui.",
        "prefs-tabs-navigation-hint": "Tip: Anda dapat menggunakan tombol panah kiri dan kanan untuk bernavigasi antartab di dalam daftar tab.",
        "userrights": "Manajemen hak pengguna",
-       "userrights-lookup-user": "Mengatur kelompok pengguna",
+       "userrights-lookup-user": "Pilih seorang pengguna",
        "userrights-user-editname": "Masukkan nama pengguna:",
-       "editusergroup": "Sunting kelompok {{GENDER:$1|pengguna}}",
+       "editusergroup": "Muat kelompok pengguna",
        "editinguser": "Mengubah hak pengguna untuk {{GENDER:$1|pengguna}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "Melihat hak pengguna dari {{GENDER:$1|pengguna}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Sunting kelompok pengguna",
+       "userrights-viewusergroup": "Lihat kelompok pengguna",
        "saveusergroups": "Simpan kelompok {{GENDER:$1|pengguna}}",
        "userrights-groupsmember": "Anggota dari:",
        "userrights-groupsmember-auto": "Anggota implisit dari:",
        "grant-group-high-volume": "Melakukan aktivitas yang amat banyak",
        "grant-group-customization": "Kustomisasi dan preferensi",
        "grant-group-administration": "Melakukan tindakan administratif",
+       "grant-group-private-information": "Akses data pribadi tentang Anda",
        "grant-group-other": "Aktivitas lain-lain",
        "grant-blockusers": "Blokir dan buka pemblokiran pengguna",
        "grant-createaccount": "Buat akun",
        "grant-highvolume": "Penyuntingan dengan volume tinggi",
        "grant-oversight": "Sembunyikan pengguna dan revisinya",
        "grant-patrol": "Tandai halaman terpatroli",
+       "grant-privateinfo": "Akses informasi pribadi",
        "grant-protect": "Melindungi dan membuka perlindungan halaman",
        "grant-rollback": "Membalikkan perubahan pada halaman",
        "grant-sendemail": "Mengirim surel kepada pengguna lain",
        "grant-basic": "Akses dasar",
        "grant-viewdeleted": "Melihat halaman dan berkas yang dihapus",
        "grant-viewmywatchlist": "Lihat daftar pantauan Anda",
+       "grant-viewrestrictedlogs": "Lihat entri log terbatas",
        "newuserlogpage": "Log pengguna baru",
        "newuserlogpagetext": "Di bawah ini adalah log pendaftaran pengguna baru",
        "rightslog": "Log perubahan hak akses",
        "action-upload_by_url": "memuatkan berkas ini dari sebuah alamat URL",
        "action-writeapi": "menggunakan API penulisan",
        "action-delete": "menghapus halaman ini",
-       "action-deleterevision": "menghapus revisi ini",
-       "action-deletedhistory": "melihat versi terdahulu halaman yang telah dihapus ini",
+       "action-deleterevision": "menghapus revisi",
+       "action-deletelogentry": "hapus entri log",
+       "action-deletedhistory": "melihat versi terdahulu halaman yang telah dihapus",
+       "action-deletedtext": "lihat teks revisi yang dihapus",
        "action-browsearchive": "mencari halaman-halaman yang telah dihapus",
-       "action-undelete": "membatalkan penghapusan halaman ini",
-       "action-suppressrevision": "meninjau dan mengembalikan revisi yang disembunyikan ini",
+       "action-undelete": "batalkan penghapusan halaman",
+       "action-suppressrevision": "tinjau dan kembalikan revisi yang disembunyikan",
        "action-suppressionlog": "melihat log privat ini",
        "action-block": "Blokir pengguna ini dari penyuntingan",
        "action-protect": "mengganti tingkat pelindungan halaman ini",
        "action-userrights-interwiki": "menyunting hak akses dari pengguna di wiki lain",
        "action-siteadmin": "mengunci atau membuka kunci basis data",
        "action-sendemail": "kirim surel",
+       "action-editmyoptions": "sunting preferensi Anda",
        "action-editmywatchlist": "sunting daftar pantauan Anda",
        "action-viewmywatchlist": "lihat daftar pantau Anda",
        "action-viewmyprivateinfo": "lihat informasi pribadi Anda",
        "action-applychangetags": "terapkan tag bersamaan dengan perubahan Anda",
        "action-changetags": "menambah dan menghapus tag semaunya pada revisi individu dan entri log",
        "action-deletechangetags": "hapus tag dari basis data",
+       "action-purge": "hapus singgahan halaman ini",
        "nchanges": "$1 {{PLURAL:$1|perubahan|perubahan}}",
        "enhancedrc-since-last-visit": "$1 {{PLURAL:$1|sejak kunjungan terakhir}}",
        "enhancedrc-history": "riwayat",
        "emailccsubject": "Salinan pesan Anda untuk $1: $2",
        "emailsent": "Surel terkirim",
        "emailsenttext": "Surel Anda telah dikirimkan.",
-       "emailuserfooter": "Email ini dikirimkan oleh $1 ke $2 dengan fungsi \"{{int:emailuser}}\" di {{SITENAME}}.",
+       "emailuserfooter": "Surel ini telah {{GENDER:$1|dikirim}} oleh $1 kepada {{GENDER:$2|$2}} dengan fungsi \"{{int:emailuser}}\" pada {{SITENAME}}. Surel {{GENDER:$2|Anda}} akan dikirim langsung kepada {{GENDER:$1|pengirim asal}}, dengan menampilkan alamat surel {{GENDER:$2|Anda}} kepada {{GENDER:$1|mereka}}.",
        "usermessage-summary": "Tinggalkan pesan sistem.",
        "usermessage-editor": "Penyampai pesan sistem",
        "usermessage-template": "MediaWiki:UserMessage",
        "modifiedarticleprotection": "mengubah tingkat pelindungan \"[[$1]]\"",
        "unprotectedarticle": "menghilangkan perlindungan dari \"[[$1]]\"",
        "movedarticleprotection": "memindahkan pengaturan proteksi dari \"[[$2]]\" ke \"[[$1]]\"",
+       "protectedarticle-comment": "{{GENDER:$2|Melindungi}} \"[[$1]]\"",
+       "modifiedarticleprotection-comment": "{{GENDER:$2|Mengubah tingkat perlindungan}} untuk \"[[$1]]\"",
+       "unprotectedarticle-comment": "{{GENDER:$2|Menghapus perlindungan}} dari \"[[$1]]\"",
        "protect-title": "Melindungi \"$1\"",
        "protect-title-notallowed": "Lihat tingkat perlindungan dari \"$1\"",
        "prot_1movedto2": "[[$1]] dipindahkan ke [[$2]]",
        "undeletehistorynoadmin": "Halaman ini telah dihapus.\nAlasan penghapusan diberikan pada ringkasan di bawah ini, berikut rincian pengguna yang telah melakukan penyuntingan pada halaman ini sebelum dihapus. Isi terakhir dari revisi yang telah dihapus ini hanya tersedia untuk pengurus.",
        "undelete-revision": "Revisi yang telah dihapus dari $1 (pada $5, $4) oleh $3:",
        "undeleterevision-missing": "Revisi salah atau tak ditemukan. Anda mungkin mengikuti pranala yang salah, atau revisi tersebut telah dipulihkan atau dibuang dari arsip.",
+       "undeleterevision-duplicate-revid": "{{PLURAL:$1|Sebuah revisi|$1 revisi}} tidak dapat dipulihkan, karena <code>rev_id</code> {{PLURAL:$1|mereka|mereka}} sedang digunakan.",
        "undelete-nodiff": "Tidak ada revisi yang lebih lama.",
        "undeletebtn": "Kembalikan",
        "undeletelink": "lihat/kembalikan",
        "undeletedrevisions": "$1 {{PLURAL:$1|revisi|revisi}} telah dikembalikan",
        "undeletedrevisions-files": "$1 {{PLURAL:$1|revisi|revisi}} and $2 berkas dikembalikan",
        "undeletedfiles": "$1 {{PLURAL:$1|berkas|berkas}} dikembalikan",
-       "cannotundelete": "Pembatalan penghapusan gagal:\n$1",
+       "cannotundelete": "Beberapa pembatalan penghapusan gagal:\n$1",
        "undeletedpage": "'''$1 berhasil dikembalikan'''\n\nLihat [[Special:Log/delete|log penghapusan]] untuk data penghapusan dan pengembalian.",
        "undelete-header": "Lihat [[Special:Log/delete|log penghapusan]] untuk daftar halaman yang baru dihapus.",
        "undelete-search-title": "Cari halaman yang dihapus",
        "sp-contributions-newbies-sub": "Untuk pengguna baru",
        "sp-contributions-newbies-title": "Kontribusi pengguna baru",
        "sp-contributions-blocklog": "log pemblokiran",
-       "sp-contributions-suppresslog": "kontribusi pengguna yang disembunyikan",
-       "sp-contributions-deleted": "kontribusi pengguna yang dihapus",
+       "sp-contributions-suppresslog": "kontribusi {{GENDER:$1|pengguna}} yang disembunyikan",
+       "sp-contributions-deleted": "kontribusi {{GENDER:$1|pengguna}} yang dihapus",
        "sp-contributions-uploads": "unggahan",
        "sp-contributions-logs": "log",
        "sp-contributions-talk": "bicara",
        "sp-contributions-username": "Alamat IP atau nama pengguna:",
        "sp-contributions-toponly": "Tampilkan hanya revisi teratas",
        "sp-contributions-newonly": "Hanya tampilkan suntingan yang berupa pembuatan halaman",
+       "sp-contributions-hideminor": "Sembunyikan suntingan kecil",
        "sp-contributions-submit": "Cari",
        "whatlinkshere": "Pranala balik",
        "whatlinkshere-title": "Halaman yang memiliki pranala ke \"$1\"",
        "movelogpagetext": "Di bawah ini adalah log pemindahan halaman.",
        "movesubpage": "{{PLURAL:$1|Subhalaman|Subhalaman}}",
        "movesubpagetext": "Halaman ini memiliki $1 {{PLURAL:$1|subhalaman|subhalaman}} seperti ditampilkan berikut.",
+       "movesubpagetalktext": "Halaman pembicaraan terkait mempunyai $1 {{PLURAL:$1|subhalaman|subhalaman}} yang tampil di bawah ini.",
        "movenosubpage": "Halaman ini tak memiliki subhalaman.",
        "movereason": "Alasan:",
        "revertmove": "batalkan",
        "pageinfo-article-id": "ID Halaman",
        "pageinfo-language": "Bahasa isi halaman",
        "pageinfo-content-model": "Model isi halaman",
+       "pageinfo-content-model-change": "ubah",
        "pageinfo-robot-policy": "Pengindeksan oleh robot",
        "pageinfo-robot-index": "Diperbolehkan",
        "pageinfo-robot-noindex": "Tidak diperbolehkan",
        "pageinfo-category-pages": "Jumlah halaman",
        "pageinfo-category-subcats": "Jumlah subkategori",
        "pageinfo-category-files": "Jumlah berkas",
+       "pageinfo-user-id": "ID pengguna",
        "markaspatrolleddiff": "Tandai telah dipatroli",
        "markaspatrolledtext": "Tandai halaman ini telah dipatroli",
        "markaspatrolledtext-file": "Tandai versi berkas sebagai terpatroli",
        "patrol-log-header": "Ini adalah log revisi terpatroli.",
        "log-show-hide-patrol": "$1 log patroli",
        "log-show-hide-tag": "log tag $1",
+       "confirm-markpatrolled-button": "OK",
+       "confirm-markpatrolled-top": "Tandai revisi $3 dari $2 sebagai terperiksa?",
        "deletedrevision": "Revisi lama yang dihapus $1",
        "filedeleteerror-short": "Kesalahan waktu menghapus berkas: $1",
        "filedeleteerror-long": "Terjadi kesalahan sewaktu menghapus berkas:\n\n$1",
        "tags-actions-header": "Tindakan",
        "tags-active-yes": "Ya",
        "tags-active-no": "Tidak",
-       "tags-source-extension": "Ditetapkan oleh suatu ekstensi",
+       "tags-source-extension": "Ditetapkan oleh perangkat lunak",
        "tags-source-manual": "Digunakan secara manual oleh pengguna dan bot",
        "tags-source-none": "Tidak digunakan lagi",
        "tags-edit": "sunting",
        "tags-deactivate": "nonaktifkan",
        "tags-hitcount": "$1 {{PLURAL:$1|perubahan}}",
        "tags-manage-no-permission": "Anda tak memiliki hak akses untuk mengatur perubahan tag.",
-       "tags-manage-blocked": "Anda tidak dapat mengganti tag ketika sedang diblokir.",
+       "tags-manage-blocked": "Anda tidak dapat mengatur perubahan tag ketika {{GENDER:$1|Anda}} diblokir.",
        "tags-create-heading": "Buat sebuah tag baru",
        "tags-create-explanation": "Secara baku, tag yang baru dibuat akan tersedia untuk digunakan oleh pengguna dan bot.",
        "tags-create-tag-name": "Nama tag:",
        "tags-create-warnings-below": "Apakah Anda ingin melanjutkan pembuatan tanda ini?",
        "tags-delete-title": "Hapus tag",
        "tags-delete-explanation-initial": "Anda akan menghapus tag \"$1\" dari basisdata.",
+       "tags-delete-explanation-warning": "Tindakan ini <strong>tidak bisa dikembalikan</strong> dan <strong>tidak bisa dibatalkan</strong> oleh siapa pun termasuk pengurus basis data. Pastikan sebaik-baiknya bahwa inilah tag yang ingin Anda hapus.",
        "tags-delete-reason": "Alasan:",
+       "tags-delete-submit": "Hapus tag ini juga",
+       "tags-delete-not-allowed": "Tag yang diberikan oleh ekstensi tidak dapat dihapus kecuali ekstensi tersebut mengizinkan.",
+       "tags-delete-not-found": "Tag \"$1\" tidak ada.",
+       "tags-delete-too-many-uses": "Tag \"$1\" diterapkan ke $2 atau lebih {{PLURAL:$2|revisi|revisi}} yang artinya tag tersebut tidak dapat dihapus.",
+       "tags-delete-warnings-after-delete": "Tag \"$1\" dihapus, namun {{PLURAL:$2|peringatan|peringatan}} berikut menemukan:",
+       "tags-delete-no-permission": "Anda tak memiliki hak akses untuk menghapus perubahan tag.",
+       "tags-activate-title": "Aktifkan tag",
+       "tags-activate-question": "Anda akan mengaktifkan tag \"$1\".",
        "tags-activate-reason": "Alasan:",
+       "tags-activate-not-allowed": "Tag \"$1\" tidak mungkin dapat diaktifkan.",
+       "tags-activate-not-found": "Tag \"$1\" tidak ada.",
        "tags-activate-submit": "Aktifkan",
+       "tags-deactivate-title": "Nonaktifkan tag",
+       "tags-deactivate-question": "Anda akan menonaktifkan tag \"$1\".",
        "tags-deactivate-reason": "Alasan:",
+       "tags-deactivate-not-allowed": "Tag \"$1\" tidak mungkin dapat dinonaktifkan.",
        "tags-deactivate-submit": "Matikan",
-       "tags-apply-blocked": "Anda tidak dapat menerapkan perubahan tag dan perubahan lainnya ketika sedang diblokir.",
-       "tags-update-blocked": "Anda tidak dapat menambah atau menghapus tag ketika sedang diblokir.",
+       "tags-apply-no-permission": "Anda tidak memiliki izin untuk menerapkan perubahan tag bersama-sama dengan perubahan Anda.",
+       "tags-apply-blocked": "Anda tidak dapat menerapkan perubahan tag dengan perubahan Anda ketika {{GENDER:$1|Anda}} sedang diblokir.",
+       "tags-apply-not-allowed-one": "Tag \"$1\" tidak diizinkan untuk diterapkan secara manual.",
+       "tags-apply-not-allowed-multi": "{{PLURAL:$2|Tag|Tag}} berikut tidak diizinkan untuk diterapkan secara manual: $1",
+       "tags-update-no-permission": "Anda tidak memiliki izin untuk menambah atau menghapus perubahan tag dari revisi atau entri log individu.",
+       "tags-update-blocked": "Anda tidak dapat menambahkan atau menghapus perubahan tag ketika {{GENDER:$1|Anda}} sedang diblokir.",
+       "tags-edit-title": "Sunting tag",
+       "tags-edit-manage-link": "Kelola tag",
+       "tags-edit-revision-selected": "{{PLURAL:$1|Revisi terpilih|Revisi terpilih}} dari [[:$2]]:",
+       "tags-edit-logentry-selected": "{{PLURAL:$1|Log peristiwa terpilih|Log peristiwa terpilih}}:",
+       "tags-edit-revision-legend": "Tambah atau hapus tag dari {{PLURAL:$1|revisi ini|semua revisi $1}}",
+       "tags-edit-logentry-legend": "Tambah atau hapus tag dari {{PLURAL:$1|entri log ini|semua entri log $1}}",
        "tags-edit-existing-tags": "Tag yang ada:",
        "tags-edit-existing-tags-none": "<em>Tidak ada</em>",
        "tags-edit-new-tags": "Tag baru:",
        "htmlform-cloner-create": "Tambahkan lebih banyak",
        "htmlform-cloner-delete": "Hapus",
        "htmlform-cloner-required": "Paling sedikit satu nilai diperlukan.",
+       "htmlform-date-placeholder": "TTTT-BB-HH",
+       "htmlform-time-placeholder": "JJ:MM:DD",
+       "htmlform-datetime-placeholder": "TTTT-BB-HH JJ:MM:DD",
+       "htmlform-date-invalid": "Nilai yang diberikan tidak dikenali sebagai tanggal. Coba lagi menggunakan format TTTT-BB-HH.",
        "htmlform-title-badnamespace": "[[:$1]] tidak berada dalam ruang nama \"{{ns:$2}}\".",
        "htmlform-title-not-creatable": "\"$1\" bukan merupakan judul halaman yang dapat dibuat",
        "htmlform-title-not-exists": "$1 tidak ada.",
        "htmlform-user-not-exists": "<strong>$1</strong> tidak ada.",
        "htmlform-user-not-valid": "<strong>$1</strong> bukan merupakan nama pengguna sah.",
        "logentry-delete-delete": "$1 {{GENDER:$2|menghapus}} halaman $3",
+       "logentry-delete-delete_redir": "$1 {{GENDER:$2|menghapus}} pengalihan $3 dengan penimpaan",
        "logentry-delete-restore": "$1 {{GENDER:$2|mengembalikan}} halaman $3",
        "logentry-delete-event": "$1 {{GENDER:$2|mengubah}} tampilan {{PLURAL:$5|$5 log peristiwa}} di $3: $4",
        "logentry-delete-revision": "$1 {{GENDER:$2|mengubah}} tampilan {{PLURAL:$5|$5  revisi}} di halaman $3: $4",
        "feedback-thanks": "Terima kasih! Umpan balik Anda telah dikirimkan ke halaman \"[$2 $1]\".",
        "feedback-thanks-title": "Terima kasih!",
        "feedback-useragent": "Agen pengguna:",
-       "searchsuggest-search": "Cari",
+       "searchsuggest-search": "Cari {{SITENAME}}",
        "searchsuggest-containing": "berisi...",
        "api-error-autoblocked": "Alamat IP Anda telah diblokir secara otomatis, karena sebelumnya digunakan oleh pengguna yang diblokir.",
        "api-error-badaccess-groups": "Anda tidak diizinkan mengunggah berkas ke wiki ini.",
        "mw-widgets-dateinput-no-date": "Tanggal tidak ada yang terpilih",
        "mw-widgets-dateinput-placeholder-day": "TTTT-BB-HH",
        "mw-widgets-dateinput-placeholder-month": "TTTT-BB",
+       "mw-widgets-mediasearch-input-placeholder": "Cari media",
+       "mw-widgets-mediasearch-noresults": "Tidak ada hasil ditemukan.",
        "mw-widgets-titleinput-description-new-page": "halaman belum ada",
        "mw-widgets-titleinput-description-redirect": "mengalihkan ke $1",
+       "mw-widgets-categoryselector-add-category-placeholder": "Tambah sebuah kategori...",
        "sessionmanager-tie": "Tidak dapat menggabungkan banyak jenis otentikasi permintaan: $1.",
        "sessionprovider-generic": "sesi $1",
        "sessionprovider-mediawiki-session-cookiesessionprovider": "sesi berdasarkan kuki",
        "log-action-filter-newusers": "Jenis pembuatan akun:",
        "log-action-filter-patrol": "Jenis patroli:",
        "log-action-filter-protect": "Jenis perlindungan:",
-       "log-action-filter-rights": "Jenis penggantian hak",
-       "log-action-filter-suppress": "Jenis penyembunyian",
+       "log-action-filter-rights": "Jenis penggantian hak akses:",
+       "log-action-filter-suppress": "Jenis penyembunyian:",
        "log-action-filter-upload": "Jenis pengunggahan:",
        "log-action-filter-all": "Semua",
        "log-action-filter-block-block": "Blokir",
        "log-action-filter-contentmodel-change": "Ubah Modelkonten",
        "log-action-filter-contentmodel-new": "Pembuatan halaman dengan Modelkonten yang tak baku",
        "log-action-filter-delete-delete": "Penghapusan halaman",
+       "log-action-filter-delete-delete_redir": "Mengalihkan pengalihan",
        "log-action-filter-delete-restore": "Pembatalan penghapusan halaman",
        "log-action-filter-delete-event": "Log penghapusan",
        "log-action-filter-delete-revision": "Penghapusan revisi",
        "authmanager-authn-autocreate-failed": "Pembuatan otomatis dari akun lokal gagal: $1",
        "authmanager-change-not-supported": "Kredensial yang diberikan tidak dapat diganti, karena tidak ada yang akan menggunakannya.",
        "authmanager-create-disabled": "Pembuatan akun dimatikan.",
-       "authmanager-create-from-login": "Untuk membuat akun Anda, silakan isi kolom di bawah.",
+       "authmanager-create-from-login": "Untuk membuat akun, silakan isi kolom di bawah.",
        "authmanager-create-not-in-progress": "Pembuatan akun tidak dilanjutkan atau data sesi telah hilang. Ulang kembali dari awal.",
        "authmanager-create-no-primary": "Kredensial yang diberikan tidak dapat digunakan untuk pembuatan akun.",
        "authmanager-link-no-primary": "Kredensial yang diberikan tidak dapat digunakan untuk menautkan akun.",
        "linkaccounts-success-text": "Akun telah ditautkan.",
        "linkaccounts-submit": "Tautkan akun",
        "unlinkaccounts": "Lepastautkan akun",
-       "unlinkaccounts-success": "Akun berikut telah dilepastautkan."
+       "unlinkaccounts-success": "Akun berikut telah dilepastautkan.",
+       "restrictionsfield-badip": "Alamat IP atau rentang IP tidak sah: $1",
+       "restrictionsfield-label": "Rentang IP yang diizinkan:",
+       "restrictionsfield-help": "Satu alamat IP atau rentang CIDR per baris. Untuk mengaktifkan semuanya, gunakan <br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "pageid": "ID halaman $1"
 }
index cdfc48c..82783c1 100644 (file)
        "editusergroup": "Modifica gruppi utente",
        "editinguser": "Modifica in corso dei diritti dell'{{GENDER:$1|utente}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Modifica gruppi utente",
+       "userrights-viewusergroup": "Visualizza gruppi utente",
        "saveusergroups": "Salva gruppi {{GENDER:$1|utente}}",
        "userrights-groupsmember": "Appartiene {{PLURAL:$1|al gruppo|ai gruppi}}:",
        "userrights-groupsmember-auto": "Membro implicito di:",
        "emailccsubject": "Copia del messaggio inviato a $1: $2",
        "emailsent": "Messaggio inviato",
        "emailsenttext": "Il messaggio e-mail è stato inviato.",
-       "emailuserfooter": "Questa email è stata {{GENDER:$1|inviata}} da $1 a {{GENDER:$2|$2}} attraverso la funzione \"{{int:emailuser}}\" su {{SITENAME}}.",
+       "emailuserfooter": "Questa email è stata {{GENDER:$1|inviata}} da $1 a {{GENDER:$2|$2}} attraverso la funzione \"{{int:emailuser}}\" su {{SITENAME}}. La {{GENDER:$2|tua}} eventuale email di risposta sarà inviata direttamente al {{GENDER:$1|mittente originale}}, rivelando il  {{GENDER:$2|tuo}} indirizzo di posta elettronica a {{GENDER:$1|lui|lei}}.",
        "usermessage-summary": "Messaggio di sistema",
        "usermessage-editor": "Messaggero di sistema",
        "usermessage-template": "MediaWiki:MessaggioUtente",
index 5e555e6..d07c6a6 100644 (file)
        "action-upload_by_url": "URL からのこのファイルのアップロード",
        "action-writeapi": "書き込みAPIの使用",
        "action-delete": "このページの削除",
-       "action-deleterevision": "この版の削除",
-       "action-deletedhistory": "このページの削除履歴の閲覧",
+       "action-deleterevision": "版の削除",
+       "action-deletelogentry": "記録項目の削除",
+       "action-deletedhistory": "ページの削除履歴の閲覧",
        "action-browsearchive": "削除されたページの検索",
-       "action-undelete": "ã\81\93ã\81®ã\83\9aã\83¼ã\82¸ã\81®å¾©å\85\83",
+       "action-undelete": "ページの復元",
        "action-suppressrevision": "隠された版の確認と復元",
        "action-suppressionlog": "非公開記録の閲覧",
        "action-block": "この利用者の編集ブロック",
index c1c62c3..25c1aab 100644 (file)
        "preview": "Pratuduh",
        "showpreview": "Deleng pratuduh",
        "showdiff": "Tuduhaké owahan",
-       "anoneditwarning": "<strong>Penget:</strong> Panjenengan boten mlebet log. Alamat IP Panjenengan badhe katingal dening publik manawi Panjenengan ngayahi ewah-ewahan. Manawi Panjenengan  <strong>[$1 mlebet log]</strong> utawai <strong>[$2 damel akun]</strong>, suntingan Panjenengan badhe kaatribusekaken dhumateng  nama pangangge Panjenengan, lan rupi-rupi  kauntungan sanesipun.",
+       "anoneditwarning": "<strong>Pènget:</strong> Panjenengan durung mlebu log. Alamat IP-né panjenengan bakal katon marang wong akèh manawa panjenengan mbesut. Manawa panjenengan <strong>[$1 mlebu log]</strong> utawa <strong>[$2 nggawé akun]</strong>, besutané panjenengan bakal dadi darbéné naragunané panjenengan lan uga ana kauntungan liya.",
        "anonpreviewwarning": "''Sampéyan durung mlebu log. Nyimpen bakal nyathet alamat IP Sampéyan nèng riwayat sunting kaca iki.''",
        "missingsummary": "'''Pènget:''' Panjenengan ora nglebokaké ringkesan panyuntingan. Menawa panjenengan mencèt tombol Simpen manèh, suntingan panjenengan bakal kasimpen tanpa ringkesan panyuntingan.",
        "selfredirect": "<strong>Pélik:</strong> Sampéyan ngalih kaca iki iya nyang kaca iki dhéwé.\nSampéyan mungkin salah wènèh tujuan kanggo alihan utawa salah mbesut kaca.\nYèn sampéyan ngeklik \"{{int:savearticle}}\" manèh, kaca alihan bakal digawé.",
        "movepage-moved": "<strong>\"$1\" wis dilih nyang \"$2\"</strong>",
        "movepage-moved-redirect": "Kaca pengalihan wis kacipta.",
        "movepage-moved-noredirect": "Kanggo gawé pengalihan wis ditahan.",
-       "articleexists": "Satunggalipun kaca kanthi asma punika sampun wonten, utawi asma ingkang panjenengan pendhet mboten leres. Sumangga nyobi asma sanèsipun.",
+       "articleexists": "Kaca mawa jeneng mangkono wis ana utawa jeneng sing kokpilih ora valid.\nMangga pilih jeneng liya.",
        "cantmove-titleprotected": "Panjenengan ora bisa mindhahaké kaca iki menyang lokasi iki, amerga irah-irahan tujuan lagi direksa; ora olèh digawé",
        "movetalk": "Lih kaca parembugan sing magepokan",
        "move-subpages": "Lih anak kaca (tekan $1)",
index 590caf6..f7ad3d9 100644 (file)
        "mypage": "Жеке бет",
        "mytalk": "Талқылау",
        "anontalk": "Талқылау",
-       "navigation": "Ð\91аÒ\93Ñ\8bÑ\82Ñ\82ау",
+       "navigation": "ШаÑ\80лау",
        "and": "&#32;және",
        "qbfind": "Табу",
        "qbbrowse": "Шолу",
        "undeleterevisions": "$1 {{PLURAL:$1|нұсқа|нұсқа}} жойылды",
        "undeletehistory": "Егер бетті қалпына келтірсеңіз тарихындағы барлық түзетулер де қалпына келтіріледі. Егер жоюдан соң дәл солай атауымен жаңа бет басталса қалпына келтірілген түзетулер бұрынғы өңделу тарихында көрсетіледі.",
        "undeleterevdel": "Егер бұл үстіңгі бетте аяқталса, не файл түзетуі жарым-жартылай жойылған болса, жою болдырмауы орындалмайды.\nОсындай жағдайларда, ең жаңа жойылған түзетуін алып тастауыңыз не жасыруын болдырмауыңыз жөн.",
-       "undeletehistorynoadmin": "Бұл бет жойылған.\nЖою себебі алдындағы өңдеген қатысушылар егжей-тегжейлерімен бірге төмендегі қысқаша мазмұндамасында көрсетілген.\nМына жойылған түзетулерін көкейкесті мәтіні тек әкімшілерге жетімді.",
+       "undeletehistorynoadmin": "Бұл бет жойылған.\nЖойған себебі жою алдындағы өңдеген қатысушылар егжей-тегжейлерімен бірге төмендегі қысқаша мазмұндамасында көрсетілген. Осы жойылған нұсқалардың мәтіні тек әкімшілерге қатынаулы.",
        "undelete-revision": "$4,  $5  кезіндегі $3 жасаған $1 дегеннің жойылған түзетуі:",
        "undeleterevision-missing": "Жарамсыз не жоғалған түзету.\nСілтемеңіз жарамсыз, не түзету қалпына келтірілген, немесе мұрағаттан аласталған болуы мүмкін.",
        "undelete-nodiff": "Еш алдыңғы түзету табылмады.",
index 387f558..d0b2f85 100644 (file)
        "minoredit": "사소한 편집입니다",
        "watchthis": "이 문서 주시하기",
        "savearticle": "문서 저장",
-       "savechanges": "변경 사항 저장",
+       "savechanges": "변경사항 저장",
        "publishpage": "문서 게시",
-       "publishchanges": "변경 사항 게시",
+       "publishchanges": "변경사항 게시",
        "preview": "미리 보기",
        "showpreview": "미리 보기",
        "showdiff": "차이 보기",
        "editusergroup": "사용자 그룹 불러오기",
        "editinguser": "<strong>[[User:$1|$1]]</strong> $2 {{GENDER:$1|사용자}}의 권한 바꾸기",
        "userrights-editusergroup": "사용자 그룹 편집",
+       "userrights-viewusergroup": "사용자 그룹 보기",
        "saveusergroups": "{{GENDER:$1|사용자}} 권한 저장",
        "userrights-groupsmember": "현재 권한:",
        "userrights-groupsmember-auto": "자동으로 부여된 권한:",
        "grant-editprotected": "보호된 문서 편집하기",
        "grant-highvolume": "대용량 편집",
        "grant-oversight": "사용자 숨기기와 판 억제",
-       "grant-patrol": "페이지 변경 사항 점검",
+       "grant-patrol": "문서의 변경사항 점검",
        "grant-privateinfo": "개인 정보 접근",
        "grant-protect": "문서 보호 및 보호 해제",
        "grant-rollback": "문서의 바뀜을 되돌리기",
        "action-upload_by_url": "URL 주소를 통해 이 파일을 올리기",
        "action-writeapi": "API를 작성할",
        "action-delete": "이 문서 삭제하기",
-       "action-deleterevision": "이 판을 삭제",
+       "action-deleterevision": "판을 삭제",
        "action-deletedhistory": "이 문서의 삭제된 기여의 역사 보기",
        "action-browsearchive": "삭제된 문서 검색",
        "action-undelete": "이 문서 되살리기",
        "usercssispublic": "주목해 주십시오: CSS의 하위 문서들은 다른 사용자들이 볼 수 있기 때문에 기밀 데이터를 포함해서는 안 됩니다.",
        "restrictionsfield-badip": "유효하지 않은 IP 주소나 대역: $1",
        "restrictionsfield-label": "허용된 IP 대역:",
-       "restrictionsfield-help": "줄 단위의 하나의 IP 주소 또는 CIDR 대역입니다. 모든 곳에 적용하려면, 다음을 사용하세요<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "줄 단위의 하나의 IP 주소 또는 CIDR 대역입니다. 모든 곳에 적용하려면, 다음을 사용하세요<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "pageid": "페이지 ID $1"
 }
index b032e60..1fd8000 100644 (file)
        "action-upload_by_url": "Fichiere vun enger Internetadress (URL) eropzelueden",
        "action-writeapi": "d'API mat Schreifzougrëff ze benotzen",
        "action-delete": "dës Säit ze läschen",
-       "action-deleterevision": "dës Versioun ze läschen",
-       "action-deletedhistory": "d'Lëscht vun de geläschte Versiounen gesinn",
+       "action-deleterevision": "Versioune läschen",
+       "action-deletedhistory": "déi geläscht Versiounen vun enger Säit weisen",
        "action-browsearchive": "no geläschte Säiten ze sichen",
-       "action-undelete": "dës Säit ze restauréieren",
-       "action-suppressrevision": "déi verstoppt Versioun kucken a restauréieren",
+       "action-undelete": "Säite restauréieren",
+       "action-suppressrevision": "verstoppt Versiounen nokucken a restauréieren",
        "action-suppressionlog": "dës privat Lëscht ze kucken",
        "action-block": "dëse Benotzer fir Ännerungen ze spären",
        "action-protect": "de Protektiounsstatus vun dëser Säit änneren",
        "action-userrights-interwiki": "d'Rechter vu Benotzer vun anere Wikien z'änneren",
        "action-siteadmin": "d'Datebank ze spären oder d'Spär opzehiewen",
        "action-sendemail": "Maile schécken",
+       "action-editmyoptions": "ännert Är Astellungen",
        "action-editmywatchlist": "ännert Är Iwwerwaachungslëscht",
        "action-viewmywatchlist": "kuckt Är Iwwerwaachungslëscht",
        "action-viewmyprivateinfo": "Är privat Informatioune kucken",
        "emailccsubject": "Kopie vun denger Noriicht un $1: $2",
        "emailsent": "E-Mail geschéckt",
        "emailsenttext": "Är E-Mail gouf fortgeschéckt.",
-       "emailuserfooter": "Dës E-Mail gouf  {{GENDER:$1|vum}} $1  {{GENDER:$2|dem}} $2 geschéckt dobäi gouf d'Funktioun \"{{int:emailuser}}\" op {{SITENAME}} benotzt.",
+       "emailuserfooter": "Dës E-Mail gouf {{GENDER:$1|vum}} $1  {{GENDER:$2|dem}} $2 geschéckt dobäi gouf d'Funktioun \"{{int:emailuser}}\" op {{SITENAME}} benotzt. {{GENDER:$2|Är}} E-Mail gëtt direkt un den {{GENDER:$1|originalen Absender}} geschéckt do bäi gesäit  {{GENDER:$1|deen}} {{GENDER:$2|Är}} E-Mail-Adress.",
        "usermessage-summary": "Benoriichtegung hannerloossen.",
        "usermessage-editor": "Benoriichtegungs-System",
        "watchlist": "Iwwerwaachungslëscht",
        "unlinkaccounts-success": "De Benotzerkont gouf getrennt.",
        "userjsispublic": "DEnkt drun: Op JavaScript-Ënnersäite solle keng vertraulech Informatioune stoe well se vun anere Benotzer kënne gesi ginn.",
        "restrictionsfield-badip": "Net valabel IP-Adress oder Beräich: $1",
-       "restrictionsfield-label": "Zougeloossen IP-Beräicher:"
+       "restrictionsfield-label": "Zougeloossen IP-Beräicher:",
+       "revid": "r$1"
 }
index 0b8c8c4..233b95f 100644 (file)
        "passwordreset-emaildisabled": "Šajā viki ir atspējotas e-pasta iespējas.",
        "passwordreset-username": "Lietotājvārds:",
        "passwordreset-domain": "Domēns:",
-       "passwordreset-capture": "Apskatīt izveidoto e-pastu?",
        "passwordreset-email": "E-pasta adrese:",
        "passwordreset-emailtitle": "Konta informācija {{SITENAME}}",
        "passwordreset-emailelement": "Lietotājvārds: \n$1\n\nPagaidu parole: \n$2",
        "userrights-reason": "Iemesls:",
        "userrights-no-interwiki": "Tev nav atļaujas izmainīt dalībnieku tiesības citos wiki.",
        "userrights-nodatabase": "Datubāze $1 neeksistē vai nav lokāla.",
-       "userrights-nologin": "Tev ir [[Special:UserLogin|jāieiet iekšā]] kā adminam, lai varētu izmainīt dalībnieku grupas.",
-       "userrights-notallowed": "Tev nav atļaujas pievienot vai noņemt dalībnieku tiesības.",
        "userrights-changeable-col": "Grupas, kuras tu vari izmainīt",
        "userrights-unchangeable-col": "Grupas, kuras tu nevari izmainīt",
        "group": "Grupa:",
        "right-userrights-interwiki": "Mainīt dalīnieku tiesības citās Vikipēdijās",
        "right-siteadmin": "Bloķēt un atbloķēt datubāzi",
        "right-sendemail": "Sūtīt e-pastu citiem dalībniekiem",
-       "right-passwordreset": "Apskatīt paroles atiestatīšanas e-pasta ziņojumus",
        "grant-group-email": "Sūtīt e-pastu",
        "grant-createaccount": "Izveidot kontu",
        "grant-editmywatchlist": "Labot uzraugāmo rakstu sarakstu",
        "htmlform-cloner-create": "Pievienot vairāk",
        "htmlform-cloner-delete": "Noņemt",
        "logentry-delete-delete": "$1 {{GENDER:$2|izdzēsa}} lapu $3",
+       "logentry-delete-delete_redir": "$1 {{GENDER:$2|izdzēsa}} pāradresāciju $3 pārrakstot",
        "logentry-delete-restore": "$1 {{GENDER:$2|atjaunoja}} lapu $3",
        "revdelete-content-hid": "saturs slēpts",
        "revdelete-summary-hid": "labojuma kopsavilkums slēpts",
        "authmanager-realname-label": "Tavs īstais vārds",
        "authmanager-realname-help": "Dalībnieka īstais vārds",
        "authprovider-resetpass-skip-label": "Izlaist",
-       "specialpage-securitylevel-not-allowed-title": "Nav atļauts",
-       "edit-error-short": "Kļūda: $1",
-       "edit-error-long": "Kļūdas:\n\n$1"
+       "specialpage-securitylevel-not-allowed-title": "Nav atļauts"
 }
index 1ecf683..831218c 100644 (file)
        "userrights-user-editname": "Внесете корисничко име:",
        "editusergroup": "Вчитај кориснички групи",
        "editinguser": "Менување на правата на {{GENDER:$1|корисникот}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "Поглед на правата на {{GENDER:$1|корисникот}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Уреди ги корисничките групи",
+       "userrights-viewusergroup": "Преглед на корисничките групи",
        "saveusergroups": "Зачувај ги {{GENDER:$1|корисничките}} групи",
        "userrights-groupsmember": "Член на:",
        "userrights-groupsmember-auto": "Подразбран член на:",
        "action-upload_by_url": "подигни ја податотекава од URL-адреса",
        "action-writeapi": "употребете запишување во извршникот",
        "action-delete": "избриши ја страницава",
-       "action-deleterevision": "избриши ја ревизијава",
-       "action-deletedhistory": "прегледај ја историјата на бришења за оваа страница",
+       "action-deleterevision": "бришење преработки",
+       "action-deletelogentry": "бришење на дневнички записи",
+       "action-deletedhistory": "преглед на историјата на бришења на оваа страница",
+       "action-deletedtext": "преглед на текст на избришани преработки",
        "action-browsearchive": "барање на избришани страници",
-       "action-undelete": "обнови Ñ\98а Ñ\81Ñ\82Ñ\80аниÑ\86ава",
-       "action-suppressrevision": "прегледај ја и обнови ја оваа скриена преработка",
+       "action-undelete": "обнова Ð½Ð° Ñ\81Ñ\82Ñ\80аниÑ\86и",
+       "action-suppressrevision": "преглед ја и обнова на скриени преработки",
        "action-suppressionlog": "преглед на овој li;en дневник",
        "action-block": "оневозможување на уредувањето на корисников",
        "action-protect": "измени го степенот на заштита на оваа страница",
        "action-userrights-interwiki": "уредување на кориснички права на корисници на други викија",
        "action-siteadmin": "заклучување или отклучување на базата на податоци",
        "action-sendemail": "испраќање на е-пошта",
+       "action-editmyoptions": "уредување на вашите нагодувања",
        "action-editmywatchlist": "уредување на мои набљудувани",
        "action-viewmywatchlist": "преглед на вашиот список на набљудувања",
        "action-viewmyprivateinfo": "преглед на вашите лични податоци",
        "emailccsubject": "Копија од вашата порака до $1: $2",
        "emailsent": "Писмото е испратено",
        "emailsenttext": "Писмото е испратено.",
-       "emailuserfooter": "$1 го испрати писмово на {{GENDER:$2|$2}} со помош на функцијата „{{int:emailuser}}“ на {{SITENAME}}.",
+       "emailuserfooter": "$1 го испрати писмово на {{GENDER:$2|$2}} со помош на функцијата „{{int:emailuser}}“ на {{SITENAME}}. {{GENDER:$2|Вашата}} е-пошта ќе му биде испратена право на {{GENDER:$1|изворниот испраќач}}, откривајќи {{GENDER:$1|му}} ја {{GENDER:$2|вашата}} адреса.",
        "usermessage-summary": "Оставете системска порака.",
        "usermessage-editor": "Системски гласник",
        "usermessage-template": "MediaWiki:КорисникПорака",
        "usercssispublic": "Напомена: потстраниците со CSS не треба да содржат дсоверливи податоци бидејќи истите се видливи и за други корисници.",
        "restrictionsfield-badip": "Неважечки IP-дијапазон на адреси: $1",
        "restrictionsfield-label": "Допуштени IP-опсези:",
-       "restrictionsfield-help": "Една IP-адреса или CIDR-опсег по ред. За да овозможите сè, користете<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "Една IP-адреса или CIDR-опсег по ред. За да овозможите сè, користете<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "revid": "п$1",
+       "pageid": "назнака на страницата $1"
 }
index 7407749..54f3004 100644 (file)
        "sat": "7 ilhui",
        "january": "Icce metztli",
        "february": "Icome metztli",
-       "march": "3 Metz",
-       "april": "Ic nāuhtetl mētztli",
-       "may_long": "Ic mācuīlli mētztli",
-       "june": "Ic chicuacē mētztli",
-       "july": "7 Metz",
-       "august": "8 Metz",
-       "september": "9 Metz",
-       "october": "10 Metz",
+       "march": "Ic yetetl metztli",
+       "april": "Ic nauhtetl metztli",
+       "may_long": "Ic macuiltetl metztli",
+       "june": "Ic chicuacentetl metztli",
+       "july": "Ic chicontetl metztli",
+       "august": "Ic chicuetetl metztli",
+       "september": "Ic chiucnahtetl metztli",
+       "october": "Ic mahtlactetl metztli",
        "november": "11 Metz",
        "december": "12 Metz",
        "january-gen": "Ic cē mētztli",
        "site-atom-feed": "$1 Atom huelītiliztli",
        "page-rss-feed": "\"$1\" RSS huelītiliztli",
        "page-atom-feed": "\"$1\" RSS huelitiliztli",
-       "red-link-title": "$1 (ahmo oncah tlahcuilolli)",
+       "red-link-title": "$1 (ahmo oncah tlahcuilolamatl)",
        "nstab-main": "Tlahcuilolamatl",
        "nstab-user": "Tequitiuhqui itlahcuilolamauh",
        "nstab-media": "Mēdiatl",
index 7ed322e..1f70032 100644 (file)
        "action-upload_by_url": "laste opp denne filen fra en URL",
        "action-writeapi": "bruke skrive-API-en",
        "action-delete": "slette denne siden",
-       "action-deleterevision": "slette denne revisjonen",
+       "action-deleterevision": "slett revisjoner",
        "action-deletedhistory": "se denne sidens slettede historikk",
        "action-browsearchive": "søke i slettede sider",
        "action-undelete": "gjenopprette denne siden",
index 3493eb7..eb65fbf 100644 (file)
        "views": "Afichatges",
        "toolbox": "Aisinas",
        "tool-link-userrights": "Modificar los gropes de {{GENDER:$1|l’utilizaire|l’utilizaira}}",
+       "tool-link-userrights-readonly": "Veire los {{GENDER:$1|gropes utilizaire}}",
        "tool-link-emailuser": "Mandar un corrièr electronic a {{GENDER:$1|l’utilizaire|l’utilizaira}}",
        "userpage": "Pagina d'utilizaire",
        "projectpage": "Pagina meta",
        "passwordreset-emaildisabled": "Las foncionalitats e-mail son estadas desactivadas sus aqueste wiki.",
        "passwordreset-username": "Nom d'utilizaire :",
        "passwordreset-domain": "Domeni:",
-       "passwordreset-capture": "Veire lo corrièl resultant ?",
-       "passwordreset-capture-help": "Se marcatz aquesta casa, lo corrièr electronic (amb lo senhal temporari) vos serà afichat al meteis temps que serà mandat a l'utilizaire.",
        "passwordreset-email": "Adreça de corrièr electronic :",
        "passwordreset-emailtitle": "Detailhs d'un compte per {{SITENAME}}",
        "passwordreset-emailtext-ip": "Qualqu'un (probablament vos, dempuèi l'adreça IP $1) a demandat una reïnicializacion de vòstre senhal per {{SITENAME}} ($4). {{PLURAL:$3|Lo compte d'utilizaire seguent es associat|Los comptes d'utilizaires seguents son associats}} a aquesta adreça de corrièr electronic :\n\n$2\n\n{{PLURAL:$3|Aqueste senhal temporari expirarà|Aquestes senhals temporaris expiraràn}} dins {{PLURAL:$5|un jorn|$5 jorns}}. Ara, vos cal vos connectar e causir un senhal novèl. Se aquesta demanda proven pas de vos, o que vos sètz remembrat de vòstre senhal inicial, e que volètz pas mai lo modificar, podètz ignorar aqueste messatge e contunhar d'utilizar vòstre ancian senhal.",
        "columns": "Colomnas :",
        "searchresultshead": "Recèrca",
        "stub-threshold": "Limit pel formatatge dels ligams d’esbòs ($1) :",
+       "stub-threshold-sample-link": "exemple",
        "stub-threshold-disabled": "Desactivat",
        "recentchangesdays": "Nombre de jorns d'afichar dins los darrièrs cambiaments :",
        "recentchangesdays-max": "(maximum $1 {{PLURAL:$1|jorn|jorns}})",
        "prefs-help-recentchangescount": "Aquò inclutz las modificacions recentas, las paginas d’istorics e los jornals.",
        "prefs-help-watchlist-token2": "Aquí la clau secreta del flux Web de vòstra lista de seguiment.\nTota persona que la coneis poirà legir vòstra lista de seguiment, doncas, la comuniquetz pas.\n[[Special:ResetTokens|Clicatz aicí se la vos cal reïnicializar]].",
        "savedprefs": "Las preferéncias son estadas salvadas.",
+       "savedrights": "Los dreits d'utilizaire de {{GENDER:$1|$1}} son estats enregistrats.",
        "timezonelegend": "Fus orari :",
        "localtime": "Ora locala :",
        "timezoneuseserverdefault": "Utilizar la valor del servidor ($1)",
        "badsig": "Signatura bruta incorrècta, verificatz vòstras balisas HTML.",
        "badsiglength": "Vòstra signatura es tròp longa.\nDeu aver, al maximum $1 caractèr{{PLURAL:$1||s}}.",
        "yourgender": "Cossí vos agrada mai d'èsser descrit ?",
-       "gender-unknown": "M'agrada mai sens detalh",
+       "gender-unknown": "Quand farà mencion de vos, lo logicial utilizarà de mots de genre neutre, quand serà possible",
        "gender-male": "Modifica de pagina del wiki",
        "gender-female": "Modifica de paginas del wiki",
        "prefs-help-gender": "Definir aquesta preferéncia es facultatiu.\nAqueste logicial utiliza sa valor per s’adreçar a vos e vos mencionar als autres en utilizant lo bon genre gramatical.\nAquesta informacion serà publica.",
        "prefs-help-prefershttps": "Aquesta preferéncia serà efectiva al moment de vòstra connexion que ven.",
        "prefs-tabs-navigation-hint": "Astúcia : Podètz utilizar las sagetas d'esquèrra e de dreita per navigar entre los onglets.",
        "userrights": "Gestion dels dreits d'utilizaire",
-       "userrights-lookup-user": "Gestion dels dreits d'utilizaire",
+       "userrights-lookup-user": "Seleccionar un utilizaire",
        "userrights-user-editname": "Entrar un nom d’utilizaire :",
-       "editusergroup": "Modificacion dels gropes d’{{GENDER:$1|utilizaires}}",
+       "editusergroup": "Cargar de gropes d’utilizaires",
        "editinguser": "Modificacion dels dreits de l’{{GENDER:$1|utilizaire|utilizaira}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Modificar los gropes de l’utilizaire",
        "saveusergroups": "Enregistrar los gropes de l’{{GENDER:$1|utilizaire|utilizaira}}",
        "userrights-reason": "Motiu :",
        "userrights-no-interwiki": "Sètz pas abilitat per modificar los dreits dels utilizaires sus d'autres wikis.",
        "userrights-nodatabase": "La basa de donadas « $1 » existís pas o es pas en local.",
-       "userrights-nologin": "Vos cal [[Special:UserLogin|vos connectar]] amb un compte d'administrator per balhar los dreits d'utilizaire.",
-       "userrights-notallowed": "Avètz pas la permission d'apondre o suprimir de dreits d'utilizaire.",
        "userrights-changeable-col": "Los gropes que podètz cambiar",
        "userrights-unchangeable-col": "Los gropes que podètz pas cambiar",
        "userrights-conflict": "Conflicte de modificacion de dreits d'utilizaire ! Relegissètz e confirmatz vòstras modificacions.",
-       "userrights-removed-self": "Avètz suprimit vòstres pròpris dreits. Del còp, podètz pas mai accedir a aquesta pagina.",
        "group": "Grop :",
        "group-user": "Utilizaires",
        "group-autoconfirmed": "Utilizaires enregistrats",
        "right-siteadmin": "Verrolhar e desverrolhar la basa de donadas",
        "right-override-export-depth": "Exportar las paginas en incluent las paginas ligadas fins a una prigondor de 5 nivèls",
        "right-sendemail": "Mandar un corrièl als autres utilizaires",
-       "right-passwordreset": "Veire los corrièrs electronics de reïnicializacion dels senhals",
        "right-applychangetags": "Aplicar [[Special:Tags|las balisas]] amb sas pròprias modificacions",
        "grant-generic": "ensemble de dreits « $1 »",
+       "grant-group-email": "Mandar un corrièr electronic",
        "grant-blockusers": "Blocar e desblocar d'utilizaires",
+       "grant-createaccount": "Crear de comptes",
+       "grant-createeditmovepage": "Crear, modificar e desplaçar de paginas",
        "grant-patrol": "Verificar las modificacions de paginas",
+       "grant-basic": "Dreits de basa",
        "newuserlogpage": "Istoric de las creacions de comptes",
        "newuserlogpagetext": "Jornal de las creacions de comptes d'utilizaires.",
        "rightslog": "Istoric de las modificacions d'estatut",
        "recentchanges-label-plusminus": "La talha de la pagina a cambiat d'aqueste nombre d’octets.",
        "recentchanges-legend-heading": "<strong>Legenda :</strong>",
        "recentchanges-legend-newpage": "{{int:recentchanges-label-newpage}} (veire tanben la [[Special:NewPages|lista de las paginas novèlas]]).",
+       "recentchanges-submit": "Afichar",
        "rcnotefrom": "Çaijós {{PLURAL:$5|la modificacion efectuada|las modificacions efectuadas}} dempuèi lo <strong>$3, $4</strong> (afichadas fins a <strong>$1</strong>).",
        "rclistfrom": "Afichar las modificacions novèlas dempuèi lo $3 $2",
        "rcshowhideminor": "$1 los cambiaments menors",
        "rcshowhidemine": "$1 mas modificacions",
        "rcshowhidemine-show": "Afichar",
        "rcshowhidemine-hide": "Amagar",
+       "rcshowhidecategorization": "$1 la categorizacion de las paginas",
+       "rcshowhidecategorization-show": "Afichar",
+       "rcshowhidecategorization-hide": "Amagar",
        "rclinks": "Afichar los $1 darrièrs cambiaments efectuats al cors dels $2 darrièrs jorns<br />$3.",
        "diff": "dif",
        "hist": "ist",
        "recentchangeslinked-summary": "Aquesta pagina especiala fa veire los darrièrs cambiaments sus las paginas que son ligadas. Las paginas de [[Special:Watchlist|vòstra lista de seguimznt]] son '''en gras'''.",
        "recentchangeslinked-page": "Nom de la pagina :",
        "recentchangeslinked-to": "Afichar los cambiaments cap a las paginas ligadas al luòc de la pagina donada",
+       "recentchanges-page-added-to-category": "[[:$1]] apondut a la categoria",
        "upload": "Importar un fichièr",
        "uploadbtn": "Importar un fichièr",
        "reuploaddesc": "Anullar lo cargament e tornar al formulari.",
        "upload-too-many-redirects": "L'URL conten tròp de redireccions",
        "upload-http-error": "Una error HTTP es intervenguda : $1",
        "upload-copy-upload-invalid-domain": "La còpia dels telecargaments es pas disponibla dempuèi aqueste domeni.",
+       "upload-dialog-title": "Mandar un fichièr",
+       "upload-dialog-button-cancel": "Anullar",
+       "upload-dialog-button-back": "Retorn",
+       "upload-dialog-button-done": "Acabat",
+       "upload-dialog-button-save": "Enregistrar",
+       "upload-dialog-button-upload": "Mandar",
+       "upload-form-label-infoform-title": "Detalhs",
+       "upload-form-label-infoform-name": "Nom",
+       "upload-form-label-infoform-description": "Descripcion",
+       "upload-form-label-usage-title": "Utilizacion",
+       "upload-form-label-usage-filename": "Nom del fichièr",
+       "upload-form-label-own-work": "Soi l'autor d'aquesta òbra",
+       "upload-form-label-infoform-categories": "Categorias",
+       "upload-form-label-infoform-date": "Data",
        "backend-fail-stream": "Impossible de legir lo fichièr $1.",
        "backend-fail-backup": "Impossible de salvar lo fichièr $1.",
        "backend-fail-notexists": "Lo fichièr $1 existís pas.",
        "uploadstash-nofiles": "Avètz pas de fichièrs en cache d'impòrt.",
        "uploadstash-errclear": "La supression dels fichièrs a fracassat.",
        "uploadstash-refresh": "Actualizar la lista dels fichièrs",
+       "uploadstash-thumbnail": "afichar una miniatura",
        "invalid-chunk-offset": "Offset de segment invalid",
        "img-auth-accessdenied": "Accès refusat",
        "img-auth-nopathinfo": "PATH_INFO mancant. Vòstre servidor es pas parametrat per passar aquesta informacion.\nBenlèu que fonciona en CGI e supòrta pas img_atuh. Consultatz https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Image_Authorization.",
        "mostrevisions": "Articles mai modificats",
        "prefixindex": "Totas las paginas que començan per…",
        "prefixindex-namespace": "Totas las paginas amb prefix (espaci de noms $1)",
+       "prefixindex-submit": "Afichar",
        "prefixindex-strip": "Levar lo prefix dins la lista",
        "shortpages": "Paginas brèvas",
        "longpages": "Paginas longas",
        "protectedpages-performer": "Proteccion de l’utilizaire",
        "protectedpages-params": "Paramètres de proteccion",
        "protectedpages-reason": "Motiu",
+       "protectedpages-submit": "Afichar las paginas",
        "protectedpages-unknown-timestamp": "Desconegut",
        "protectedpages-unknown-performer": "Utilizaire desconegut",
        "protectedtitles": "Títols protegits",
        "protectedtitlesempty": "Cap de títol es pas actualament protegit amb aquestes paramètres.",
+       "protectedtitles-submit": "Afichar los títols",
        "listusers": "Lista dels participants",
        "listusers-editsonly": "Far veire sonque los utilizaires qu'an al mens una contribucion",
        "listusers-creationsort": "Triar per data de creacion",
        "usereditcount": "$1 {{PLURAL:$1|cambiament|cambiaments}}",
        "usercreated": "{{GENDER:$3|Creat}} lo $1 a $2",
        "newpages": "Paginas novèlas",
+       "newpages-submit": "Afichar",
        "newpages-username": "Nom d'utilizaire :",
        "ancientpages": "Articles mai ancians",
        "move": "Renomenar",
        "apihelp-no-such-module": "Lo modul « $1 » es introbable.",
        "apisandbox": "Nauc de sabla API",
        "apisandbox-api-disabled": "API es desactivat sus aqueste site.",
+       "apisandbox-fullscreen": "Espandir lo panèl",
+       "apisandbox-unfullscreen": "Afichar la pagina",
        "apisandbox-submit": "Far la demanda",
        "apisandbox-reset": "Escafar",
+       "apisandbox-retry": "Ensajar tornarmai",
+       "apisandbox-helpurls": "Ligams d'ajuda",
        "apisandbox-examples": "Exemples",
+       "apisandbox-dynamic-parameters": "Paramètres suplementaris",
+       "apisandbox-dynamic-parameters-add-label": "Apondon del paramètre",
+       "apisandbox-dynamic-parameters-add-placeholder": "Nom del paramètre",
+       "apisandbox-deprecated-parameters": "Paramètres obsolèts",
        "apisandbox-results": "Resultats",
        "apisandbox-request-url-label": "Requèsta URL :",
        "apisandbox-request-time": "Durada de la demanda : {{PLURAL:$1|$1 ms}}",
+       "apisandbox-continue": "Contunhar",
+       "apisandbox-continue-clear": "Escafar",
        "booksources": "Obratges de referéncia",
        "booksources-search-legend": "Recercar demest d'obratges de referéncia",
        "booksources-isbn": "ISBN :",
        "specialloguserlabel": "Autor :",
        "speciallogtitlelabel": "Cibla (títol o {{ns:user}}:nom d'utilizaire) :",
        "log": "Jornals",
+       "logeventslist-submit": "Afichar",
        "all-logs-page": "Totas las operacions publicas",
        "alllogstext": "Afichatge combinat de totes los jornals de {{SITENAME}}.\nPodètz restrénher la vista en seleccionant un tipe de jornal, un nom d’utilizaire (cassa sensibla) o una pagina ciblada (idem).",
        "logempty": "I a pas res dins l’istoric per aquesta pagina.",
        "log-title-wildcard": "Recercar de títols que començan per aqueste tèxte",
        "showhideselectedlogentries": "Afichar/amagar las entradas de jornal seleccionadas",
+       "checkbox-select": "Seleccionar : $1",
+       "checkbox-all": "Tot",
+       "checkbox-none": "Pas cap",
+       "checkbox-invert": "Inversar",
        "allpages": "Totas las paginas",
        "nextpage": "Pagina seguenta ($1)",
        "prevpage": "Pagina precedenta ($1)",
        "cachedspecial-viewing-cached-ttl": "Visualizatz una version d'aquesta pagina mesa en cache, que pòt èsser datada d’al mai $1.",
        "cachedspecial-refresh-now": "Veire lo mai recent.",
        "categories": "Categorias",
+       "categories-submit": "Afichar",
        "categoriespagetext": "{{PLURAL:$1|La categoria seguenta es utilizada|Las categorias seguentas son utilizadas}} per de paginas o de fichièrs.\n[[Special:UnusedCategories|Las categorias inutilizadas]] son pas afichadas aicí.\nVejatz tanben [[Special:WantedCategories|las categorias demandadas]].",
        "categoriesfrom": "Afichar las categorias que començan a :",
        "deletedcontributions": "Contribucions suprimidas d’un utilizaire",
        "listgrouprights-namespaceprotection-header": "Restriccions d'espaci de noms",
        "listgrouprights-namespaceprotection-namespace": "Espaci de noms",
        "listgrouprights-namespaceprotection-restrictedto": "Dreit(s) que permet(on) a l'utilizaire de modificar",
+       "listgrants": "Autorizacions",
+       "listgrants-grant": "Acordar",
+       "listgrants-rights": "Dreits",
        "trackingcategories": "Categorias de seguiment",
        "trackingcategories-msg": "Categoria de seguiment",
        "trackingcategories-name": "Nom del messatge",
        "wlheader-showupdated": "Las paginas que son estadas modificadas dempuèi vòstra darrièra visita son afichadas en '''gras'''.",
        "wlnote": "Çaijós {{PLURAL:$1|figura la darrièra modificacion efectuada|figuran las <strong>$1</strong> darrièras modificacions efectuadas}} pendent {{PLURAL:$2|la darrièra ora|las <strong>$2</strong> darrièras oras}}, dempuèi $3, $4.",
        "wlshowlast": "Far veire las darrièras $1 oras, los darrièrs $2 jorns",
+       "watchlist-hide": "Amagar",
+       "watchlist-submit": "Afichar",
        "wlshowhideminor": "cambiaments menors",
+       "wlshowhidebots": "Robòts",
+       "wlshowhideliu": "utilizaires enregistrats",
+       "wlshowhideanons": "utilizaires anonims",
+       "wlshowhidepatr": "modificacions repassadas",
+       "wlshowhidemine": "mas modificacions",
        "watchlist-options": "Opcions de la lista de seguiment",
        "watching": "Seguit...",
        "unwatching": "Fin del seguit...",
        "delete-confirm": "Escafar «$1»",
        "delete-legend": "Escafar",
        "historywarning": "<strong>Atencion :</strong> la pagina que sètz a mand de suprimir a un istoric amb $1 {{PLURAL:$1|version|versions}} :",
+       "historyaction-submit": "Afichar",
        "confirmdeletetext": "Sètz a mand de suprimir una pagina o un fichièr, e mai totas sas versions anterioras istorizadas.\nConfirmatz qu'es plan çò que volètz far, que ne comprenètz las consequéncias e que fasètz aquò en acòrdi amb las [[{{MediaWiki:Policy-url}}|règlas intèrnas]].",
        "actioncomplete": "Accion efectuada",
        "actionfailed": "L’accion a fracassat",
        "changecontentmodel-title-label": "Títol de la pagina",
        "changecontentmodel-model-label": "Novèl modèl de contengut",
        "changecontentmodel-reason-label": "Motiu :",
+       "changecontentmodel-submit": "Modificar",
        "logentry-contentmodel-change-revertlink": "restablir",
        "logentry-contentmodel-change-revert": "restablir",
        "protectlogpage": "Istoric de las proteccions",
        "ipb-unblock": "Desblocar un compte d'utilizaire o una adreça IP",
        "ipb-blocklist": "Vejatz los blocatges existents",
        "ipb-blocklist-contribs": "Contribucions per {{GENDER:$1|$1}}",
+       "ipb-blocklist-duration-left": "$1 restant",
        "unblockip": "Desblocar un utilizaire o una adreça IP",
        "unblockiptext": "Utilizatz lo formulari çaijós per restablir l'accès en escritura\na partir d'una adreça IP precedentament blocada.",
        "ipusubmit": "Suprimir aqueste blocatge",
        "pageinfo-article-id": "Numèro de la pagina",
        "pageinfo-language": "Lenga del contengut de la pagina",
        "pageinfo-content-model": "Modèl de contengut de la pagina",
+       "pageinfo-content-model-change": "modificar",
        "pageinfo-robot-policy": "Indexacion per robòts",
        "pageinfo-robot-index": "Autorizada",
        "pageinfo-robot-noindex": "Interdicha",
        "pageinfo-category-pages": "Nombre de paginas",
        "pageinfo-category-subcats": "Nombre de soscategorias",
        "pageinfo-category-files": "Nombre de fichièrs",
+       "pageinfo-user-id": "ID de l'utilizaire",
        "markaspatrolleddiff": "Marcar coma essent pas un vandalisme",
        "markaspatrolledtext": "Marcar aqueste article coma pas vandalizat",
        "markedaspatrolled": "Marcat coma pas vandalizat",
        "patrol-log-header": "Vaquí un jornal de las versions patrolhadas.",
        "log-show-hide-patrol": "$1 l'istoric de las relecturas",
        "log-show-hide-tag": "$1 lo jornal de las balisas",
+       "confirm-markpatrolled-button": "D'acòrdi",
        "deletedrevision": "La version anciana $1 es estada suprimida.",
        "filedeleteerror-short": "Error al moment de la supression del fichièr : $1",
        "filedeleteerror-long": "D'errors son estadas rencontradas al moment de la supression del fichièr :\n\n$1",
        "confirm-watch-top": "Apondre aquesta pagina a vòstra lista de seguiment ?",
        "confirm-unwatch-button": "D'acòrdi",
        "confirm-unwatch-top": "Levar aquesta pagina de vòstra lista de seguiment ?",
+       "confirm-rollback-button": "D'acòrdi",
        "colon-separator": "&nbsp;:&#32;",
        "quotation-marks": "« $1 »",
        "imgmultipageprev": "← pagina precedenta",
        "watchlisttools-edit": "Veire e modificar la lista de seguiment",
        "watchlisttools-raw": "Modificar la lista (mòde brut)",
        "signature": "[[{{ns:user}}:$1|$2]] ([[{{ns:user_talk}}:$1|discussion]])",
+       "timezone-local": "Local",
        "duplicate-defaultsort": "Atencion : La clau de triada per defaut « $2 » espotís la mai recenta « $1 ».",
        "duplicate-displaytitle": "<strong>Atencion :</strong> Lo títol d'afichatge «$2» remplaça l'ancian títol d'afichatge «$1».",
        "version": "Version",
        "redirect-page": "ID de pagina",
        "redirect-revision": "Revision de la pagina",
        "redirect-file": "Nom del fichièr",
+       "redirect-logid": "ID de jornal",
        "redirect-not-exists": "Valor pas trobada",
        "fileduplicatesearch": "Recèrca dels fichièrs en doble",
        "fileduplicatesearch-summary": "Recèrca de las còpias de fichièrs identics d'aprèp lor emprenta de hachatge.",
        "tags-actions-header": "Accions",
        "tags-active-yes": "Òc",
        "tags-active-no": "Non",
-       "tags-source-extension": "Definida per una extension",
+       "tags-source-extension": "Definit pel logicial",
        "tags-source-manual": "Aplicada manualament pels utilizaires e los bòts",
        "tags-source-none": "Obsolèt",
        "tags-edit": "modificar",
        "htmlform-cloner-create": "Apondre encara",
        "htmlform-cloner-delete": "Suprimir",
        "htmlform-cloner-required": "Una valor al mens es obligatòria.",
+       "htmlform-date-placeholder": "AAAA-MM-JJ",
+       "htmlform-time-placeholder": "HH:MM:SS",
+       "htmlform-datetime-placeholder": "AAAA-MM-JJ HH:MM:SS",
        "logentry-delete-delete": "$1 {{GENDER:$2|a suprimit}} la pagina $3",
        "logentry-delete-restore": "$1 {{GENDER:$2|a restablit}} la pagina $3",
        "logentry-delete-event": "$1 {{GENDER:$2|a modificat}} la visibilitat {{PLURAL:$5|d'un eveniment del jornal|de $5 eveniments del jornal}} sus $3 : $4",
        "mediastatistics-header-text": "Textual",
        "mediastatistics-header-executable": "Executables",
        "mediastatistics-header-archive": "Formats compressats",
+       "mediastatistics-header-total": "Totes los fichièrs",
        "json-error-state-mismatch": "JSON invalid o mal format",
        "json-error-syntax": "Error de sintaxi",
        "headline-anchor-title": "Ligam cap a aquesta seccion",
        "randomrootpage": "Pagina raiç aleatòria",
        "log-action-filter-rights": "Tipe de cambiament de dreits :",
        "log-action-filter-suppress": "Tipe de supression :",
+       "log-action-filter-all": "Tot",
+       "log-action-filter-block-block": "Blocatge",
+       "log-action-filter-block-unblock": "Desblocar",
+       "authmanager-email-label": "Corrièr electronic",
+       "authmanager-email-help": "Adreça de corrièr electronic",
+       "authmanager-realname-label": "Nom vertadièr",
+       "authmanager-realname-help": "Nom real de l'utilizaire",
+       "authprovider-resetpass-skip-label": "Sautar",
        "changecredentials": "Modificar las informacions d’identificacion"
 }
index 170ea04..4197703 100644 (file)
        "action-userrights-interwiki": "edytowania uprawnień użytkowników na innych witrynach wiki",
        "action-siteadmin": "blokowania i odblokowywania bazy danych",
        "action-sendemail": "wysyłania e-maili",
+       "action-editmyoptions": "edycja swoich preferencji",
        "action-editmywatchlist": "edycji swojej listy obserwowanych stron",
        "action-viewmywatchlist": "zobaczenia swojej listy obserwowanych stron",
        "action-viewmyprivateinfo": "zobaczenia swoich prywatnych danych",
index 1830765..368907c 100644 (file)
                        "Cristofer Alves",
                        "Tark",
                        "O Andarilho",
-                       "Bruno.S.Alves 270"
+                       "Bruno.S.Alves 270",
+                       "!Silent"
                ]
        },
        "tog-underline": "Sublinhar links:",
        "feedback-thanks": "Obrigado! O seu comentário foi adicionado à página \"[$2 $1]\".",
        "feedback-thanks-title": "Obrigado!",
        "feedback-useragent": "Agente de usuário:",
-       "searchsuggest-search": "Pesquisa",
+       "searchsuggest-search": "Pesquisar em {{SITENAME}}",
        "searchsuggest-containing": "páginas contendo…",
        "api-error-badaccess-groups": "Você não tem permissão para enviar arquivos para este wiki.",
        "api-error-badtoken": "Erro interno: token inválido.",
index bb3cb65..72d119e 100644 (file)
@@ -72,7 +72,8 @@
                        "Luan",
                        "Gato Preto",
                        "Jdforrester",
-                       "Mansil"
+                       "Mansil",
+                       "Ngl2016"
                ]
        },
        "tog-underline": "Sublinhar ligações:",
        "search-external": "Pesquisa externa",
        "searchdisabled": "Foi impossibilitada a realização de pesquisas na wiki {{SITENAME}}.\nEntretanto, pode realizar pesquisas através do Google.\nNote, no entanto, que a indexação da wiki {{SITENAME}} neste motor de busca pode estar desatualizada.",
        "search-error": "Um erro ocorreu enquanto se efectuava a pesquisa: $1",
-       "search-warning": "Foi assinalado um aviso ao pesquisar: $1",
+       "search-warning": "Ocorreu um aviso ao pesquisar: $1",
        "preferences": "Preferências",
        "mypreferences": "Preferências",
        "prefs-edits": "Número de edições:",
        "userrights-user-editname": "Introduza um nome de utilizador(a):",
        "editusergroup": "Carregar grupos do utilizador",
        "editinguser": "A modificar os privilégios {{GENDER:$1|do utilizador|da utilizadora|do(a) utilizador(a)}}  <strong>[[User:$1|$1]]</strong> $2",
-       "userrights-editusergroup": "Editar grupos {{GENDER:$1|do utilizador|da utilizadora|do(a) utilizador(a)}}",
+       "viewinguserrights": "A ver os privilégios {{GENDER:$1|do utilizador|da utilizadora}} <strong>[[User:$1|$1]]</strong> $2",
+       "userrights-editusergroup": "Editar grupos {{GENDER:$1|do utilizador|da utilizadora}}",
+       "userrights-viewusergroup": "Ver grupos do utilizador",
        "saveusergroups": "Gravar grupos {{GENDER:$1|do utilizador|da utilizadora|do(a) utilizador(a)}}",
        "userrights-groupsmember": "Membro de:",
        "userrights-groupsmember-auto": "Membro implícito de:",
        "action-upload_by_url": "enviar este ficheiro através de um URL",
        "action-writeapi": "utilizar o modo de escrita da API",
        "action-delete": "eliminar esta página",
-       "action-deleterevision": "eliminar esta edição",
-       "action-deletedhistory": "ver o histórico de edições eliminadas desta página",
+       "action-deleterevision": "eliminar revisões",
+       "action-deletelogentry": "eliminar entradas de registo",
+       "action-deletedhistory": "ver o histórico de edições eliminadas de uma página",
+       "action-deletedtext": "ver o texto de uma revisão eliminada",
        "action-browsearchive": "pesquisar páginas eliminadas",
-       "action-undelete": "restaurar esta página",
-       "action-suppressrevision": "rever e restaurar esta edição oculta",
+       "action-undelete": "restaurar páginas",
+       "action-suppressrevision": "rever e restaurar edições ocultas",
        "action-suppressionlog": "ver este registo privado",
        "action-block": "impedir este utilizador de editar",
        "action-protect": "alterar os níveis de proteção desta página",
        "action-userrights-interwiki": "editar privilégios de utilizadores de outras wikis",
        "action-siteadmin": "bloquear ou desbloquear a base de dados",
        "action-sendemail": "enviar correio eletrónico",
+       "action-editmyoptions": "editar as suas preferências",
        "action-editmywatchlist": "editar a sua lista de páginas vigiadas",
        "action-viewmywatchlist": "ver a sua lista de páginas vigiadas",
        "action-viewmyprivateinfo": "ver a sua informação privada",
        "emailccsubject": "Cópia da sua mensagem para $1: $2",
        "emailsent": "Mensagem enviada",
        "emailsenttext": "A sua mensagem foi enviada.",
-       "emailuserfooter": "Esta mensagem foi {{GENDER:$1|enviada}} por $1 para {{GENDER:$2|$2}} através da opção \"{{int:emailuser}}\" da wiki {{SITENAME}}.",
+       "emailuserfooter": "Esta mensagem foi enviada {{GENDER:$1|pelo utilizador|pela utilizadora}} $1 para {{GENDER:$2|$2}} através da opção \"{{int:emailuser}}\" da wiki {{SITENAME}}. {{GENDER:$2|A sua}} resposta será enviada diretamente para {{GENDER:$1|o|a}} remetente original, e irá revelar-lhe {{GENDER:$2|o seu}} endereço de correio eletrónico.",
        "usermessage-summary": "Deixar mensagem de sistema.",
        "usermessage-editor": "Editor de mensagens de sistema",
        "watchlist": "Páginas vigiadas",
        "usercssispublic": "Nota: As subpáginas de CSS não devem conter dados confidenciais porque podem ser vistas por outros utilizadores.",
        "restrictionsfield-badip": "Endereço IP (ou gama de endereços IP) inválido: $1",
        "restrictionsfield-label": "Gamas de endereços IP permitidas:",
-       "restrictionsfield-help": "Um endereço IP ou uma gama CIDR por linha. Para ativar todos,\nuse<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "Um endereço IP ou uma gama CIDR por linha. Para ativar todos,\nuse<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "pageid": "identificador de página $1"
 }
index fea648d..6fb46dd 100644 (file)
        "october-gen": "{{doc-months|10|genitive}}\n{{Identical|October}}",
        "november-gen": "{{doc-months|11|genitive}}\n{{Identical|November}}",
        "december-gen": "{{doc-months|12|genitive}}\n{{Identical|December}}",
-       "jan": "{{doc-months|1|short}}",
-       "feb": "{{doc-months|2|short}}",
-       "mar": "{{doc-months|3|short}}",
-       "apr": "{{doc-months|4|short}}",
-       "may": "{{doc-months|5|short}}",
-       "jun": "{{doc-months|6|short}}",
-       "jul": "{{doc-months|7|short}}",
-       "aug": "{{doc-months|8|short}}",
-       "sep": "{{doc-months|9|short}}",
-       "oct": "{{doc-months|10|short}}",
+       "jan": "{{doc-months|1|short}}\n{{Identical|January}}",
+       "feb": "{{doc-months|2|short}}\n{{Identical|February}}",
+       "mar": "{{doc-months|3|short}}\n{{Identical|March}}",
+       "apr": "{{doc-months|4|short}}\n{{Identical|April}}",
+       "may": "{{doc-months|5|short}}\n{{Identical|May}}",
+       "jun": "{{doc-months|6|short}}\n{{Identical|June}}",
+       "jul": "{{doc-months|7|short}}\n{{Identical|July}}",
+       "aug": "{{doc-months|8|short}}\n{{Identical|August}}",
+       "sep": "{{doc-months|9|short}}\n{{Identical|September}}",
+       "oct": "{{doc-months|10|short}}\n{{Identical|October}}",
        "nov": "{{doc-months|11|short}}",
        "dec": "{{doc-months|12|short}}",
        "january-date": "A date in the Gregorian month of January. $1 is the numerical date, for example \"23\".\n{{Identical|January}}",
        "february-date": "A date in the Gregorian month of February. $1 is the numerical date, for example \"23\".\n{{Identical|February}}",
        "march-date": "A date in the Gregorian month of March. $1 is the numerical date, for example \"23\".\n{{Identical|March}}",
-       "april-date": "A date in the Gregorian month of April. $1 is the numerical date, for example \"23\".",
+       "april-date": "A date in the Gregorian month of April. $1 is the numerical date, for example \"23\".\n{{Identical|April}}",
        "may-date": "A date in the Gregorian month of May. $1 is the numerical date, for example \"23\". The month name is not abbreviated.\n{{Identical|May}}",
-       "june-date": "A date in the Gregorian month of June. $1 is the numerical date, for example \"23\".",
-       "july-date": "A date in the Gregorian month of July. $1 is the numerical date, for example \"23\".",
-       "august-date": "A date in the Gregorian month of August. $1 is the numerical date, for example \"23\".",
-       "september-date": "A date in the Gregorian month of September. $1 is the numerical date, for example \"23\".",
-       "october-date": "A date in the Gregorian month of October. $1 is the numerical date, for example \"23\".",
+       "june-date": "A date in the Gregorian month of June. $1 is the numerical date, for example \"23\".\n{{Identical|June}}",
+       "july-date": "A date in the Gregorian month of July. $1 is the numerical date, for example \"23\".\n{{Identical|July}}",
+       "august-date": "A date in the Gregorian month of August. $1 is the numerical date, for example \"23\".\n{{Identical|August}}",
+       "september-date": "A date in the Gregorian month of September. $1 is the numerical date, for example \"23\".\n{{Identical|September}}",
+       "october-date": "A date in the Gregorian month of October. $1 is the numerical date, for example \"23\".\n{{Identical|October}}",
        "november-date": "A date in the Gregorian month of November. $1 is the numerical date, for example \"23\".\n{{Identical|November}}",
        "december-date": "A date in the Gregorian month of December. $1 is the numerical date, for example \"23\".",
        "period-am": "Text indicating the first period of the day when using a 12-hour calendar.",
        "action-writeapi": "{{Doc-action|writeapi}}\n\nAPI is an abbreviation for [[w:API|application programming interface]].",
        "action-delete": "{{Doc-action|delete}}",
        "action-deleterevision": "{{Doc-action|deleterevision}}",
+       "action-deletelogentry": "{{Doc-action|deletelogentry}}",
        "action-deletedhistory": "{{Doc-action|deletedhistory}}",
+       "action-deletedtext": "{{Doc-action|deletedtext}}",
        "action-browsearchive": "{{Doc-action|browsearchive}}",
        "action-undelete": "{{Doc-action|undelete}}",
        "action-suppressrevision": "{{Doc-action|suppressrevision}}",
        "action-userrights-interwiki": "{{Doc-action|userrights-interwiki}}",
        "action-siteadmin": "{{Doc-action|siteadmin}}",
        "action-sendemail": "{{doc-action|sendemail}}\n{{Identical|E-mail}}",
+       "action-editmyoptions": "{{Doc-action|editmyoptions}}",
        "action-editmywatchlist": "{{doc-action|editmywatchlist}}\n{{Identical|Edit your watchlist}}",
        "action-viewmywatchlist": "{{doc-action|viewmywatchlist}}\n{{Identical|View your watchlist}}",
        "action-viewmyprivateinfo": "{{doc-action|viewmyprivateinfo}}",
        "usercssispublic": "A reminder to users that CSS subpages are not preferences but normal pages, and thus can be viewed by other users and the general public. This message is shown to a user whenever they are editing a subpage in their own user-space that ends in .css. See also {{msg-mw|userjsispublic}}",
        "restrictionsfield-badip": "An error message shown when one entered an invalid IP address or range in a restrictions field (such as Special:BotPassword). $1 is the IP address.",
        "restrictionsfield-label": "Field label shown for restriction fields (e.g. on Special:BotPassword).",
-       "restrictionsfield-help": "Placeholder text displayed in restriction fields (e.g. on Special:BotPassword)."
+       "restrictionsfield-help": "Placeholder text displayed in restriction fields (e.g. on Special:BotPassword).",
+       "revid": "Used to format a revision ID number in text. Parameters:\n* $1 - Revision ID number.",
+       "pageid": "Used to format a page ID number in text. Parameters:\n* $1 - Page ID number."
 }
index 0d4a8b2..f6a017d 100644 (file)
        "passwordreset-emaildisabled": "Funcțiile de e-mail au fost dezactivate de pe acest wiki.",
        "passwordreset-username": "Nume de utilizator:",
        "passwordreset-domain": "Domeniu:",
-       "passwordreset-capture": "Vizualizați e-mailul rezultat?",
-       "passwordreset-capture-help": "Dacă bifați această căsuță, e-mailul (conținând parola temperară) vă va fi afișat, dar va fi trimis și utilizatorului.",
        "passwordreset-email": "Adresă de e-mail:",
        "passwordreset-emailtitle": "Detalii despre cont pe {{SITENAME}}",
        "passwordreset-emailtext-ip": "Cineva (probabil dumneavoastră, de la adresa IP $1) a solicitat resetarea parolei \npentru {{SITENAME}} ($4). {{PLURAL:$3|Următorul cont este asociat|Următoarele conturi sunt asociate}}\ncu această adresă de e-mail:\n\n$2\n\n{{PLURAL:$3|Această parolă temporară va|Aceste parole temporare vor}} expira {{PLURAL:$5|într-o zi|în $5 zile}}.\nAr trebui să vă autentificați și să schimbați parola acum. Dacă altcineva a făcut această cerere \nsau dacă v-ați reamintit parola inițială și nu mai doriți să o schimbați,\nputeți ignora acest mesaj, continuând să utilizați vechea parolă.",
        "userrights-reason": "Motiv:",
        "userrights-no-interwiki": "Nu aveți permisiunea de a modifica permisiunile utilizatorilor pe alte wiki.",
        "userrights-nodatabase": "Baza de date $1 nu există sau nu este locală.",
-       "userrights-nologin": "Trebuie să te [[Special:UserLogin|autentifici]] cu un cont de administrator pentru a atribui permisiuni utilizatorilor.",
-       "userrights-notallowed": "Nu aveți permisiunea de a acorda sau elimina drepturi utilizatorilor.",
        "userrights-changeable-col": "Grupuri pe care le puteți schimba",
        "userrights-unchangeable-col": "Grupuri pe care nu le puteți schimba",
        "userrights-conflict": "Conflict al schimbării drepturilor de utilizator! Reverificați și confirmați-vă modificările.",
-       "userrights-removed-self": "V-ați eliminat propriile drepturi. Ca urmare, nu mai puteți accesa această pagină.",
        "group": "Grup:",
        "group-user": "Utilizatori",
        "group-autoconfirmed": "Utilizatori autoconfirmați",
        "right-siteadmin": "Blochează și deblochează baza de date",
        "right-override-export-depth": "Exportă inclusiv paginile legate până la o adâncime de 5",
        "right-sendemail": "Trimite e-mail altor utilizatori",
-       "right-passwordreset": "Vizualizează e-mailurile de reinițializare a parolelor",
        "right-managechangetags": "Creează și (dez)activează [[Special:Tags|etichete]]",
        "right-applychangetags": "Aplică [[Special:Tags|etichete]] asociate modificărilor unui utilizator",
        "right-changetags": "Adaugă și înlătură [[Special:Tags|etichete]] arbitrare din versiuni și intrări de jurnal individuale",
        "grant-oversight": "Ascunde utilizatori și suprimă versiuni",
        "grant-patrol": "Patrulează schimbările paginilor",
        "grant-basic": "Drepturi de bază",
+       "grant-viewmywatchlist": "Vezi lista de pagini urmărite",
        "newuserlogpage": "Jurnal utilizatori noi",
        "newuserlogpagetext": "Acesta este jurnalul creărilor conturilor de utilizator.",
        "rightslog": "Jurnal permisiuni de utilizator",
index 807ced9..026e178 100644 (file)
@@ -47,6 +47,7 @@
        "tog-watchlistreloadautomatically": "Recareche automaticamende l'eleghe de le pàggene condrollate quanne cange 'nu filtre (richieste Javascript)",
        "tog-watchlisthideanons": "Scunne le cangiaminde de l'utinde scanusciute da l'elenghe de le pàggene condrollate",
        "tog-watchlisthidepatrolled": "Scunne le cangiaminde condrollate jndr'à l'elenghe de le pàggene condrollate",
+       "tog-watchlisthidecategorization": "Scunne 'a categorizzazzione d'a vôsce",
        "tog-ccmeonemails": "Manneme 'na copie de le mail ca je manne a l'ôtre utinde",
        "tog-diffonly": "No fà vedè le pàggene cu le condenute sotte a le differenze",
        "tog-showhiddencats": "Fa vedè le categorije scunnute",
        "talk": "'Ngazzaminde",
        "views": "Visite",
        "toolbox": "Struminde",
+       "tool-link-userrights": "Cange le gruppe {{GENDER:$1|utinde}}",
+       "tool-link-userrights-readonly": "'Ndruche le gruppe {{GENDER:$1|utinde}}",
+       "tool-link-emailuser": "Manne 'na mail a stu {{GENDER:$1|utende}}",
        "userpage": "Vide a pàgene de l'utende",
        "projectpage": "Vide a pàgene de le pruggette",
        "imagepage": "Vide a pàgene de le file",
        "userlogin-remembermypassword": "Arrecuèrdeme",
        "userlogin-signwithsecure": "Ause 'na connessione secure",
        "cannotlogin-title": "Non ge puè trasé",
+       "cannotcreateaccount-title": "Non ge pué ccrejà le cunde utinde",
        "yourdomainname": "'U nome d'u dominie tue:",
        "password-change-forbidden": "Non ge puè cangià le passuord sus a sta uicchi.",
        "externaldberror": "Vide bbuene, o stè 'n'errore de autendicazione a 'u database oppure tu non ge puè aggiorna 'u cunde tue esterne.",
        "eauthentsent": "'N'e-mail de conferme ha state mannate a l'indirizze ca tu è ditte.\nApprime ca otre e-mail avènene mannate a 'u cunde tune, tu ha seguì le 'struzione ca stonne jndr'à l'e-mail, pe confermà ca 'u cunde jè une de le tune.",
        "throttled-mailpassword": "'Nu arrecordatore de passuord ha stete già mannate jndr'à {{PLURAL:$1|l'urtema ore|l'urteme $1 ore}}.\nPe prevenì l'abbuse, sulamende 'nu arrecordatore de passuord avene mannate ogne {{PLURAL:$1|ore|$1 ore}}.",
        "mailerror": "Errore mannanne 'a mail: $1",
-       "acct_creation_throttle_hit": "Le visitature de sta Uicchi ca stonne ausene stu indirizze IP onne ccrejete {{PLURAL:$1|'nu cunde utende|$1 cunde utinde}} jndr'à l'urteme giurne, e onne raggiunde 'u numere massime ca se pò fà jndr'à stu periode.\n'U resultete jè ca le visitature ca stonne ausene stu indirizze IP non ge ponne ccrejà otre cunde utinde nuève jndr'à stu mumende.",
+       "acct_creation_throttle_hit": "Le visitature de sta Uicchi ca stonne ausene stu indirizze IP onne ccrejate {{PLURAL:$1|'nu cunde utende|$1 cunde utinde}} jndr'à l'urteme $2, e onne raggiunde 'u numere massime ca se pò fà jndr'à stu periode.\n'U resultate éte ca le visitature ca stonne ausene stu indirizze IP non ge ponne ccrejà otre cunde utinde nuève jndr'à stu mumende.",
        "emailauthenticated": "L'indirizze e-mail ca ne date ha state confermate 'u sciurne $2 a le $3.",
        "emailnotauthenticated": "L'indirizze e-mail tune non g'a state angore confermate.\nNisciuna mail t'avène mannate pe tutte le seguende dettaglie.",
        "noemailprefs": "Specifiche 'n'indirizze e-mail pe ste dettaglie ca onne essere fatiete.",
        "createacct-another-realname-tip": "'U nome vere jè facoltative.\nCe tu scacchie de metterle, quiste avène ausate pe dà 'u giuste merite a 'a fatìe de l'utende.",
        "pt-login": "Tràse",
        "pt-login-button": "Tràse",
+       "pt-login-continue-button": "Condinue a trasé",
        "pt-createaccount": "Ccreje 'nu cunde utende",
        "pt-userlogout": "Isse",
        "php-mail-error-unknown": "Errore scanusciute jndr'à funzione PHP mail()",
        "resetpass_submit": "'Mboste 'a passuord e colleghete",
        "changepassword-success": "'A password toje ha state cangiate!",
        "changepassword-throttled": "Tu è pruvate 'nu sacche de vote a trasè.\nPe piacere aspitte $1 apprime de pruvà arrete.",
+       "botpasswords": "Password d'u bot",
+       "botpasswords-label-appid": "Nome d'u bot:",
+       "botpasswords-label-create": "Ccreje",
+       "botpasswords-label-update": "Aggiorne",
+       "botpasswords-label-cancel": "Annulle",
+       "botpasswords-label-delete": "Scangìlle",
+       "botpasswords-label-resetpassword": "Azzere 'a passuord",
        "resetpass_forbidden": "Le Password non ge ponne cangià",
        "resetpass-no-info": "Tu a essere colleghete pe accedere a sta pàgene direttamende.",
        "resetpass-submit-loggedin": "Cange 'a password",
        "resetpass-submit-cancel": "Annulle",
-       "resetpass-wrong-oldpass": "'A password temboranea o quedda corrende jè invalide.\nPò essere ca tu è già cangete 'a password toje o è richieste una temboranea nove.",
+       "resetpass-wrong-oldpass": "'A password temboranée o quedda corrende non g'è valide.\nPò essere ca tu è già cangiate 'a password toje o n'è cercate una nove temboranée.",
        "resetpass-recycled": "Pe piacere azzere 'a password toje cu 'n'otra password deverse da quedde de mò.",
        "resetpass-temp-emailed": "Tu è trasute cu 'nu codece email tembaranèe.\nPe spiccià de trasè, tu ha 'mbostà 'na password nove aqquà:",
        "resetpass-temp-password": "Password temboranea:",
        "passwordreset-emailtext-ip": "Quacchedune (pò essere tu, da 'u 'ndirizze IP $1) ha richieste 'na mail pe arrecurdarse de le dettaglie d'u cunde sue pe {{SITENAME}} ($4). {{PLURAL:$3|'U cunde utende seguende jè|le cunde utinde seguende sonde}} associate cu st'indirizze e-mail:\n\n$2\n\n{{PLURAL:$3|Sta passuord temboranèe scade|Ste passuord temboranèe scadene}} 'mbrà {{PLURAL:$5|'nu sciurne|$5 sciurne}}.\nTu avissa trasè e scacchià 'na passuord nova. Ce quacchedun'otre ha fatte sta richieste, o ce tu t'è arrecurdate 'a passuord origgenale toje, e non g'a vuè ccu cange cchiù, tu puè ignorà stu messagge e condinuà ausanne 'a passuord vecchie.",
        "passwordreset-emailtext-user": "L'utende $1 sus a {{SITENAME}} ave richieste 'na mail pe arrecurdarse le dettaglie d'u cunde sue pe {{SITENAME}}\n($4). {{PLURAL:$3|'U cunde utende seguende jè|le cunde utinde seguende sonde}} associate cu st'indirizze e-mail:\n\n$2\n\n{{PLURAL:$3|Sta passuord temboranèe scade|Ste passuord temboranèe scadene}}  'mbrà {{PLURAL:$5|'nu sciurne|$5 sciurne}}.\nTu avissa trasè e scacchià 'na passuord nova. Ce quacchedun'otre ha fatte sta richieste, o ce tu t'è arrecurdate 'a passuord origgenale toje, e non g'a vuè ccu cange cchiù, tu puè ignorà stu messagge e condinuà ausanne 'a passuord vecchie.",
        "passwordreset-emailelement": "Nome utende: \n$1\n\nPassuord temboranèe: \n$2",
-       "passwordreset-emailsentemail": "Ce quiste jè 'n'e-mail pu cunde tune, allore 'na password azzerate ha state mannate addà.",
+       "passwordreset-emailsentemail": "Ce queste éte 'n'e-mail pu cunde tune, allore 'na password azzerate ha state mannate addà.",
        "changeemail": "Cange o live 'u 'ndirizze e-mail",
        "changeemail-header": "Comblete stu module pe cangià 'u 'ndirizze email. Ce tu vuè ccu live l'associazione cu ogne indirizze email da 'u cunde tune, lasse 'u 'ndirizze email vacande quanne conferme 'u module.",
        "changeemail-no-info": "Tu a essere collegate pe accedere a sta pàgene direttamende.",
        "accmailtext": "'A passuord ccrejate a uecchije pe [[User talk:$1|$1]] ha state mannate sus a $2.\n\n'A passuord pe stu cunde utende pò essere cangiate sus a pàgene ''[[Special:ChangePassword|cange passuord]]'' 'na vote ca è trasute.",
        "newarticle": "(Nuève)",
        "newarticletext": "Tu ste segue 'nu collegamende a pàgene ca angore non g'esiste.\nPe ccrejà 'a pàgene, accuminze a scrivere jndr'à 'u scatole de sotte (vide 'a [$1 pàggene d'ajute] pe avè cchiù 'mbormaziune).\nCe tu te iacche aqquà e manghe tu 'u se purcè, allore cazze 'u buttone '''back''' d'u brauser.",
-       "anontalkpagetext": "----''Queste jè 'na pàgene de 'ngazzaminde pe 'n'utende anonime, ca non ge vò ccu ccreje angore 'nu cunde utende, o de ce non g'u use.\nNuje auseme 'n'indirizze IP (ca jè numereche) pe identificarle.\nE' normale ca essende 'n'indirizze IP pò essere ausete pure da otre utinde ca 'u pigghiene.\nCe tu non ge si 'n'utende anonime e pinze ca le commende ca so revolte a te sonde studecarije, pe piacere [[Special:CreateAccount|ccreje 'nu cunde utende]] o [[Special:UserLogin|tràse]] pe no fà confusione jndr'à 'u future cu otre utinde anoneme.''",
+       "anontalkpagetext": "----\n<em>Queste jè 'na pàgene de 'ngazzaminde pe 'n'utende anonime, ca non ge vò ccu ccreje angore 'nu cunde utende, o de ce non g'u use.</em>\nNuje ausame 'n'indirizze IP (ca éte numereche) pe identificarle.\nE' normale ca pu fatte ca 'n'indirizze IP pò essere ausate pure da otre utinde ca 'u pigghiane.\nCe tu non ge si 'n'utende anonime e pinze ca le commende ca te arrivane sonde studecarije, pe piacere [[Special:CreateAccount|ccreje 'nu cunde utende]] o [[Special:UserLogin|tràse]] pe no fà confusione jndr'à 'u future cu otre utinde anoneme.",
        "noarticletext": "Non ge stè scritte ninde jndr'à sta pàgene.\nTu puè [[Special:Search/{{PAGENAME}}|cercà pe quiste titole]] jndr'à otre pàggene, <span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} cirche l'archivije sue] o [{{fullurl:{{FULLPAGENAME}}|action=edit}} ccreje sta pàgene]</span>.",
        "noarticletext-nopermission": "Pe mò non ge stè teste jndr'à sta pàgene.\nTu puè [[Special:Search/{{PAGENAME}}|cercà pe stu titole]] jndr'à otre pàggene,\no <span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} cirche jndr'à l'archivije cullegate]</span>, ma non ge tìne le permesse pe ccrejà sta pàgene.",
        "missing-revision": "'A revisione #$1 d'a pàgene chiamate \"{{FULLPAGENAME}}\" non g'esiste.\n\nQuiste succede normalmende purcé 'u cunde jè collegate a 'na pàgene ca ha state scangellate.\nLe dettaglie le puè acchià jndr'à l'[{{fullurl:{{#Special:Log}}/delete|page={{FULLPAGENAMEE}}}} archivije de le scangellaziune].",
        "userpage-userdoesnotexist": "'U cunde utende \"<nowiki>$1</nowiki>\" non g'è reggistrete.\nPe piacere, condrolle ce tu vuè cu ccreje/cange sta pàgene.",
        "userpage-userdoesnotexist-view": "'U cunde utende \"$1\" non g'è reggistrate.",
        "blocked-notice-logextract": "Stu utende jè correndemende bloccate.<br />\nL'urteme archivije de le bloccaminde se iacche aqquà sotte pe referimende:",
-       "clearyourcache": "'''Vide Bbuene''' - Apprisse 'a reggistrazione, tu puè zumbà 'a cache d'u browser tune pe vedè le cangiaminde.\n*'''Firefox / Safari:''' cazze 'u ''Shift'' e condemboraneamende cazze 'u buttone ''Aggiorna'', o cazze 'nzieme ''Ctrl-F5'' o ''Ctrl-R'' (''⌘-R'' sus a 'nu Mac);\n*'''Google Chrome:''' cazze ''Ctrl-Shift-R'' (''⌘-Shift-R'' sus a 'nu Mac)\n*'''Internet Explorer:''' cazze ''Ctrl'' e condemboraneamende cazze ''Aggiorna,'' o cazze ''Ctrl-F5''.\n*'''Opera:''' pulizze 'a cache da ''Tools → Preferences'' (in inglese) (Struminde - Preferenze in tarandine);",
+       "clearyourcache": "<strong>Vide Bbuene</strong> - Apprisse 'a reggistrazione, tu puè zumbà 'a cache d'u browser tune pe vedè le cangiaminde.\n*<strong>Firefox / Safari:</strong> cazze 'u <em>Shift</em> e condemboraneamende cazze 'u buttone <em>Aggiorne</em>, o cazze 'nzieme <em>Ctrl-F5</em> o <em>Ctrl-R</em> (<em>⌘-R</em> sus a 'nu Mac);\n*<strong>Google Chrome:</strong> cazze <em>Ctrl-Shift-R</em> (<em>⌘-Shift-R</em> sus a 'nu Mac)\n*<strong>Internet Explorer:</strong> cazze ''Ctrl'' e condemboraneamende cazze <em>Aggiorne</em> o cazze <em>Ctrl-F5</em>.\n*<strong>Opera:</strong> pulizze 'a cache da <em>Tools → Preferences</em> (in inglese) (Struminde - Preferenze in tarandine);",
        "usercssyoucanpreview": "'''Conziglie:''' Ause 'u buttone \"{{int:showpreview}}\" pe condrollà 'u CSS nuève apprime de reggistrà.",
        "userjsyoucanpreview": "'''Conziglie:''' Ause 'u buttone \"{{int:showpreview}}\" pe condrollà 'u JavaScript nuève apprime de reggistrà.",
        "usercsspreview": "'''Arrecuerdete ca tu ste vide sulamende in andeprime 'u CSS tue.'''\n'''Non g'à state angore reggistrete ninde!'''",
        "editusergroup": "Cange le gruppe utinde",
        "editinguser": "Stè cange le deritte de {{GENDER:$1|l'utende}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Cange le gruppe d'utinde",
+       "userrights-viewusergroup": "'Ndruche le gruppe d'utinde",
        "saveusergroups": "Reggistre le gruppe d'utinde",
        "userrights-groupsmember": "Membre de:",
        "userrights-groupsmember-auto": "Membre imblicite de:",
        "apisandbox-examples": "Esembie",
        "apisandbox-results": "Resultate",
        "apisandbox-request-url-label": "URL richieste:",
-       "apisandbox-request-time": "Tiembe cercate: $1",
+       "apisandbox-request-time": "Tiembe cercate: {{PLURAL:$1|$1 ms}}",
        "booksources": "Sorgende de le libbre",
        "booksources-search-legend": "Cirche pe le fonde de le libbre",
        "booksources-isbn": "ISBN:",
        "tags-actions-header": "Aziune",
        "tags-active-yes": "Sìne",
        "tags-active-no": "None",
-       "tags-source-extension": "Definite da 'n'estenzione",
+       "tags-source-extension": "Definite da 'u softuer",
        "tags-source-manual": "Applicate a màne da l'utinde e da le bot",
        "tags-source-none": "No cchiù ausate",
        "tags-edit": "cange",
        "tags-delete-not-allowed": "Tag definite da 'n'estenzione non ge ponne essere scangellate senze ca l'estenzione specifiche 'u permette.",
        "tags-delete-not-found": "'U tag \"$1\" non g'esiste.",
        "tags-delete-too-many-uses": "'U tag \"$1\" jè applecate a cchiù de $2 {{PLURAL:$2|revisione|revisiune}}, ca signifeche ca non ge pò essere scangellate.",
-       "tags-delete-warnings-after-delete": "'U tag \"$1\" ha state scangellate, ma  {{PLURAL:$2|ha assute 'u seguende avvise|onne assute le seguende avvise}}:",
+       "tags-delete-warnings-after-delete": "'U tag \"$1\" ha state scangellate, ma {{PLURAL:$2|ha assute 'u seguende avvise|onne assute le seguende avvise}}:",
        "tags-activate-title": "Attive 'u tag",
        "tags-activate-question": "Tu ste attive 'u tag \"$1\".",
        "tags-activate-reason": "Mutive:",
        "tags-edit-revision-legend": "Aggiunge o live le tag da {{PLURAL:$1|sta revisione|tutte le $1 revisiune}}",
        "tags-edit-logentry-legend": "Aggiunge o live le tag da {{PLURAL:$1|sta vôsce de l'archivije|tutte le $1 vôsce de l'archivije}}",
        "tags-edit-existing-tags": "Tag esistende:",
-       "tags-edit-existing-tags-none": "\"Nisciune\"",
+       "tags-edit-existing-tags-none": "<em>isciune</em>",
        "tags-edit-new-tags": "Tag nuève:",
        "tags-edit-add": "Agigunge ste tag:",
        "tags-edit-remove": "Live ste tag:",
index 5fcb960..1cacac4 100644 (file)
        "tog-hidepatrolled": "Скрывать патрулированные правки в списке свежих правок",
        "tog-newpageshidepatrolled": "Скрывать отпатрулированные страницы в списке новых страниц",
        "tog-hidecategorization": "Скрывать категоризацию страниц",
-       "tog-extendwatchlist": "Расширенный список наблюдения, включающий все изменения, а не только последние",
+       "tog-extendwatchlist": "Расширенный список наблюдения, включающий все изменения, а не только последние <small>(они могут быть сгруппированы настройкой на вкладке «[[Служебная:Настройки#mw-prefsection-rc|Свежие правки]]»)</small>",
        "tog-usenewrc": "Группировать изменения в свежих правках и списке наблюдения",
        "tog-numberheadings": "Автоматически нумеровать заголовки",
        "tog-showtoolbar": "Показывать панель инструментов при редактировании",
        "userrights-user-editname": "Введите имя учётной записи:",
        "editusergroup": "Загрузка групп участников",
        "editinguser": "Изменение прав {{GENDER:$1|участника|участницы}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "Просмотр прав {{GENDER:$1|участника|участницы}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Изменение членства в группах",
+       "userrights-viewusergroup": "Просмотр групп участника",
        "saveusergroups": "Сохранить группы {{GENDER:$1|участника|участницы}}",
        "userrights-groupsmember": "Состоит в группах:",
        "userrights-groupsmember-auto": "Неявно состоит в группах:",
        "action-upload_by_url": "загрузку этого файла с адреса URL",
        "action-writeapi": "использование API для правок",
        "action-delete": "удаление этой страницы",
-       "action-deleterevision": "удаление этой версии страницы",
-       "action-deletedhistory": "просмотр удалённой истории этой страницы",
+       "action-deleterevision": "удаление версий страниц",
+       "action-deletelogentry": "удаление записей журнала",
+       "action-deletedhistory": "просмотр удалённой истории страницы",
+       "action-deletedtext": "просмотр текста удалённой версии",
        "action-browsearchive": "поиск удалённых страниц",
-       "action-undelete": "воÑ\81Ñ\81Ñ\82ановление Ñ\8dÑ\82ой Ñ\81Ñ\82Ñ\80аниÑ\86Ñ\8b",
-       "action-suppressrevision": "пÑ\80оÑ\81моÑ\82Ñ\80 Ð¸ Ð²Ð¾Ñ\81Ñ\81Ñ\82ановление Ñ\8dÑ\82ой Ñ\81кÑ\80Ñ\8bÑ\82ой Ð²ÐµÑ\80Ñ\81ии Ñ\81Ñ\82Ñ\80аниÑ\86Ñ\8b",
+       "action-undelete": "воÑ\81Ñ\81Ñ\82ановление Ñ\81Ñ\82Ñ\80аниÑ\86",
+       "action-suppressrevision": "пÑ\80оÑ\81моÑ\82Ñ\80 Ð¸ Ð²Ð¾Ñ\81Ñ\81Ñ\82ановление Ñ\81кÑ\80Ñ\8bÑ\82Ñ\8bÑ\85 Ð²ÐµÑ\80Ñ\81ий Ñ\81Ñ\82Ñ\80аниÑ\86",
        "action-suppressionlog": "просмотр этого частного журнала",
        "action-block": "ограничивать возможность редактирования для этого участника",
        "action-protect": "изменение уровня защиты этой страницы",
        "action-userrights-interwiki": "изменение прав участников в других вики",
        "action-siteadmin": "блокировка и разблокировка базы данных",
        "action-sendemail": "отправка электронных писем",
+       "action-editmyoptions": "редактирование своих настроек",
        "action-editmywatchlist": "редактирование вашего списка наблюдения",
        "action-viewmywatchlist": "просмотр вашего списка наблюдения",
        "action-viewmyprivateinfo": "просмотр вашей частной информации",
        "emailccsubject": "Копия вашего сообщения для $1: $2",
        "emailsent": "Письмо отправлено",
        "emailsenttext": "Ваше электронное сообщение отправлено.",
-       "emailuserfooter": "Это письмо было отправлено {{GENDER:$2|участнику|участнице}} $2 от {{GENDER:$1|участника|участницы}} $1 с помощью функции «{{int:emailuser}}» проекта {{SITENAME}}.",
+       "emailuserfooter": "Это письмо было отправлено {{GENDER:$2|участнику|участнице}} $2 от {{GENDER:$1|участника|участницы}} $1 с помощью функции «{{int:emailuser}}» проекта {{SITENAME}}.\n{{GENDER:$2|Письмо}} будет отослано напрямую {{GENDER:$1|отправителю}}, так что {{GENDER:$2|ваш}} адрес электронной почты станет известен {{GENDER:$1|ему|ей}}.",
        "usermessage-summary": "Оставить системное сообщение.",
        "usermessage-editor": "Системная доставка",
        "watchlist": "Список наблюдения",
        "usercssispublic": "Обратите внимание: подстраницы CSS не должны содержать конфиденциальные сведения, поскольку они доступны для просмотра другим участникам.",
        "restrictionsfield-badip": "Недопустимый IP-адрес или диапазон адресов: $1",
        "restrictionsfield-label": "Разрешённые диапазоны IP-адресов:",
-       "restrictionsfield-help": "По одному IP-адресу или CIDR-диапазону в строке. Чтобы разрешить всё, используйте <br /><code>0.0.0.0/0</code><br /><code>::/0</code>"
+       "restrictionsfield-help": "По одному IP-адресу или CIDR-диапазону в строке. Чтобы разрешить всё, используйте <br /><code>0.0.0.0/0</code><br /><code>::/0</code>",
+       "pageid": "ID страницы $1"
 }
index e6aaa03..ede9988 100644 (file)
        "emailccsubject": "Эн суругуҥ куоппуйата $1: $2",
        "emailsent": "Сурук барда",
        "emailsenttext": "Эн суругуҥ ыытылынна.",
-       "emailuserfooter": "Бу сурук $2 кыттааччыга $1 кыттааччыттан «Сурукта ыыт» диэн тэрил көмөтүнэн {{SITENAME}} ситим-сиртэн ыытыллыбыт.",
+       "emailuserfooter": "Бу сурук {{GENDER:$2|$2}} кыттааччыга {{GENDER:$1|$1}} кыттааччыттан «Сурукта ыыт» (\"{{int:emailuser}}\") диэн тэрил көмөтүнэн {{SITENAME}} ситим-сиртэн ыытыллыбыт. {{GENDER:$2|Эн}} электрон аадырыһыҥ ыыппыт {{GENDER:$1|киһигэр}} көстүөҕэ.",
        "usermessage-summary": "Тиһилик биллэриитин хааллар.",
        "usermessage-editor": "Тиһилик биллэрээччитэ",
        "watchlist": "Кэтэбилим тиһигэ",
index be9c104..68cbdcc 100644 (file)
        "prefs-diffs": "تفاوت",
        "prefs-help-prefershttps": "هيءَ ترجيح توهان جي ايند داخل ٿيڻ تي عمل ۾ ايندي.",
        "userrights": "يُوزر حقن جو بندوبست",
-       "userrights-lookup-user": "يوزر گروپَ سنڀاليو",
+       "userrights-lookup-user": "ڪو يوزر چونڊيو",
        "userrights-user-editname": "يُوزرنانءُ ڄاڻايو:",
-       "editusergroup": "{{GENDER:$1|يوزر}} گروھ ترميميو",
+       "editusergroup": "يوزر گروھ اتاريو",
        "userrights-editusergroup": "يوزر گروپَ سنواريو",
        "saveusergroups": "{{GENDER:$1|يوزر}} گروھ سانڍيو",
        "userrights-groupsmember": "برڪن:",
index 6154b85..eed382e 100644 (file)
        "userrights-user-editname": "Vpišite uporabniško ime:",
        "editusergroup": "Naloži uporabniške skupine",
        "editinguser": "Urejanje pravic {{GENDER:$1|uporabnika|uporabnice}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "Ogledovanje uporabniških pravic {{GENDER:$1|uporabnika|uporabnice}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Urejanje uporabniških skupin",
+       "userrights-viewusergroup": "Ogled skupin uporabnikov",
        "saveusergroups": "Shrani {{GENDER:$1|uporabnikove|uporabničine}} skupine",
        "userrights-groupsmember": "Član skupine:",
        "userrights-groupsmember-auto": "Posreden član:",
        "action-upload_by_url": "nalaganje te datoteke iz URL-naslova",
        "action-writeapi": "uporabo API-ja za pisanje",
        "action-delete": "brisanje te strani",
-       "action-deleterevision": "brisanje te redakcije",
-       "action-deletedhistory": "pregled zgodovine izbrisanih redakcij te strani",
+       "action-deleterevision": "brisanje redakcij",
+       "action-deletelogentry": "brisanje dnevniških vnosov",
+       "action-deletedhistory": "ogled zgodovine izbrisanih redakcij strani",
+       "action-deletedtext": "ogled besedila izbrisanih redakcij",
        "action-browsearchive": "iskanje izbrisanih strani",
-       "action-undelete": "obnavljanje te strani",
-       "action-suppressrevision": "vpogled in obnavljanje te skrite redakcije",
+       "action-undelete": "obnavljanje strani",
+       "action-suppressrevision": "vpogled in obnavljanje skritih redakcij",
        "action-suppressionlog": "vpogled tega zasebnega dnevnika",
        "action-block": "blokiranje urejanja s tega uporabniškega računa",
        "action-protect": "spremembo stopnje zaščite te strani",
        "action-userrights-interwiki": "upravljanje uporabniških pravic za uporabnike drugih wikijev",
        "action-siteadmin": "zaklenitev ali odklepanje podatkovne baze",
        "action-sendemail": "pošiljanje e-sporočil",
+       "action-editmyoptions": "urejanje svojih nastavitev",
        "action-editmywatchlist": "urejanje svojega spiska nadzorov",
        "action-viewmywatchlist": "ogleda svojega spiska nadzorov",
        "action-viewmyprivateinfo": "ogled svojih zasebnih informacij",
        "usercssispublic": "Pomnite: Podstrani CSS naj ne vsebujejo zaupnih podatkov, saj so vidne tudi drugim uporabnikom.",
        "restrictionsfield-badip": "Neveljaven IP-naslov ali obseg: $1",
        "restrictionsfield-label": "Dovoljeni IP-obsegi:",
-       "restrictionsfield-help": "En IP-naslov ali CIDR-območje na vrstico. Da omogočite vse, uporabite<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "En IP-naslov ali CIDR-območje na vrstico. Da omogočite vse, uporabite<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "pageid": "ID strani $1"
 }
index f3f52f1..3f3c720 100644 (file)
        "passwordreset-emaildisabled": "Karakteristikat e  Email janë të paaftë në këtë wiki.",
        "passwordreset-username": "Nofka:",
        "passwordreset-domain": "Domain:",
-       "passwordreset-capture": "Dëshiron të shikosh e-mail-in që rezulton?",
-       "passwordreset-capture-help": "Nëse shënoni këtë kuti, e-mail-i (dhe fjalekalimi i përkohshëm) që do t'i dërgohen përdoruesit, do të të tregohen edhe ty.",
        "passwordreset-email": "Posta elektronike",
        "passwordreset-emailtitle": "Detajet e llogarisë në {{SITENAME}}",
        "passwordreset-emailtext-ip": "Dikush (ndoshta ju, nga IP adresa $1) kërkoi një kujtesë për \ndetajet e llogarisë suaj {{SITENAME}} ($4).Përdoruesi në vijim {{PLURAL:$3|llogari është|llogaritë janë}} të lidhur me këtë postë elektronike:\n\n$2\n\n{{PLURAL:$3|Ky fjalëkalim i përkohshëm|Këto fjalëkalime të përkohshme}} do të përfundojë për {{PLURAL:$5|një ditë|$5 ditë}}.\n\nJu duhet të kyçeni dhe të zgjidhni një fjalëkalim të ri tani. Nëse dikush tjetër e ka bërë këtë kërkesës, ose në qoftë se ju mbani mend fjalëkalimin tuaj origjinal, dhe ju nuk dëshirojni të ndryshoni atë, ju mund të injoroni këtë mesazh dhe do të vazhdoni përdorimin e fjalëkalimit tuaj të vjetër.",
        "blockedtitle": "Përdoruesi është bllokuar",
        "blockedtext": "'''Llogaria juaj ose adresa e IP është bllokuar'''\n\nBllokimi u bë nga $1 dhe arsyeja e dhënë ishte '''$2'''.\n\n*Fillimi i bllokimit: $8\n*Skadimi i bllokimit: $6\n*I bllokuari i shënjestruar: $7\n\nMund të kontaktoni $1 ose një nga [[{{MediaWiki:Grouppage-sysop}}|administruesit]] e tjerë për të diskutuar bllokimin.\n\nVini re se nuk mund t'i dërgoni email përdoruesit nëse nuk keni një adresë të saktë të dhënë tek [[Special:Preferences|parapëlqimet e përdoruesit]] ose nëse kjo është një nga mundësitë që ju është bllokuar.\n\nAdresa e IP-së që keni është $3 dhe numri i identifikimit të bllokimit është #$5. Përfshini këto dy të dhëna në çdo ankesë.",
        "autoblockedtext": "IP adresa juaj është bllokuar automatikisht sepse ishte përdorur nga një përdorues tjetër i cili ishte bllokuar nga $1.\nArsyeja e dhënë për këtë është:\n\n:''$2''\n\n* Fillimi i bllokimit: $8\n* Kalimi i kohës së bllokimit: $6\n* Zgjatja e bllokimit: $7\n\nJu mund të kontaktoni $1 ose një tjetër [[{{MediaWiki:Grouppage-sysop}}|administrues]] për ta diskutuar bllokimin.\n\nVini re : që nuk mund ta përdorni mundësinë \"dërgo porosi elektronike\" përveç nëse keni një postë elektronike të vlefshme të regjistruar në [[Special:Preferences|preferencat tuaja]] dhe nuk jeni bllokuar nga përdorimi i saj.\n\nIP adresa juaj e tanishme është $3 dhe ID e bllokimit është #$5.\nJu lutemi përfshini këto detaje në të gjitha kërkesat që i bëni.",
-       "blockednoreason": "nuk është dhënë ësnje arsye",
+       "blockednoreason": "nuk është dhënë asnjë arsye",
        "whitelistedittext": "Ju duhet të $1 për të redaktuar faqet.",
        "confirmedittext": "Ju duhet së pari ta vërtetoni e-mail adresen para se të redaktoni. Ju lutem plotësoni dhe vërtetoni e-mailin tuaj  te [[Special:Preferences|parapëlqimet]] e juaja.",
        "nosuchsectiontitle": "Paragrafi nuk mund të gjendet",
        "userrights-reason": "Arsyeja:",
        "userrights-no-interwiki": "Nuk keni leje për të ndryshuar privilegjet e përdoruesve në wiki të tjera.",
        "userrights-nodatabase": "Regjistri $1 nuk ekziston ose nuk është vendor.",
-       "userrights-nologin": "Duhet të [[Special:UserLogin|hyni brenda]] me një llogari administrative për të ndryshuar privilegjet e përdoruesve.",
-       "userrights-notallowed": "Ju nuk keni leje për të shtuar ose hequr privilegjet e përdoruesve.",
        "userrights-changeable-col": "Grupe që mund të ndryshoni",
        "userrights-unchangeable-col": "Grupe që s'mund të ndryshoni",
        "userrights-conflict": "Konflikt në ndryshimin e të drejtave të përdoruesit! Të lutem të rishiko dhe konfirmo ndryshimet e tua.",
        "right-siteadmin": "Mbyll ose hap bazën e të dhënave",
        "right-override-export-depth": "Eksoprto faqet duke përfshirë e lidhura deri në një thellësi prej 5",
        "right-sendemail": "Dërgo e-mail tek përdoruesit e tjerë",
-       "right-passwordreset": "Shiko e-mail-et e rivendosjes së fjalëkalimit",
        "right-managechangetags": "Krijoni dhe fshini [[Special:Tags|tags]] nga baza e të dhënave",
        "right-applychangetags": "Aplikoni [[Special:Tags|tags]] së bashku me ndryshimet",
        "right-changetags": "Shtoni dhe të largoni në mënyrë arbitrare [[Special:Tags|tags]] në rishikimet individuale dhe regjistrimet e historikut",
index c24dcb6..d4f9cbb 100644 (file)
        "views": "Visningar",
        "toolbox": "Verktyg",
        "tool-link-userrights": "Ändra {{GENDER:$1|användargrupper}}",
+       "tool-link-userrights-readonly": "Visa {{GENDER:$1|användargrupper}}",
        "tool-link-emailuser": "Skicka e-post till denna {{GENDER:$1|användare}}",
        "userpage": "Visa användarsida",
        "projectpage": "Visa projektsida",
        "search-external": "Extern sökning",
        "searchdisabled": "Sökfunktionen på {{SITENAME}} är avstängd.\nDu kan istället göra sökningar med hjälp av Google.\nNotera dock att deras indexering av {{SITENAME}} kan vara något föråldrad.",
        "search-error": "Ett fel uppstod under sökningen: $1",
+       "search-warning": "En varning uppstod under sökning: $1",
        "preferences": "Inställningar",
        "mypreferences": "Inställningar",
        "prefs-edits": "Antal redigeringar:",
        "prefswarning-warning": "Du har gjort ändringar i dina inställningarna som inte har sparats ännu.\nOm du lämnar denna sida utan att klicka på \"$1\" kommer dina inställningar inte att uppdateras.",
        "prefs-tabs-navigation-hint": "Tips: Du kan använda vänster och höger piltangenterna för att navigera mellan flikarna i listan flikar.",
        "userrights": "Hantering av användarrättigheter",
-       "userrights-lookup-user": "Hantera användargrupper",
+       "userrights-lookup-user": "Välj en användare",
        "userrights-user-editname": "Skriv in ett användarnamn:",
-       "editusergroup": "Ändra {{GENDER:$1|användargrupper}}",
+       "editusergroup": "Läs in användargrupper",
        "editinguser": "Ändrar rättigheter för {{GENDER:$1|användaren}} <strong>[[User:$1|$1]]</strong> $2",
+       "viewinguserrights": "Visar rättigheter för {{GENDER:$1|användaren}} <strong>[[User:$1|$1]]</strong> $2",
        "userrights-editusergroup": "Ändra användargrupper",
+       "userrights-viewusergroup": "Visa användargrupper",
        "saveusergroups": "Spara {{GENDER:$1|användargrupper}}",
        "userrights-groupsmember": "Medlem i:",
        "userrights-groupsmember-auto": "Implicit medlem av:",
        "action-upload_by_url": "ladda upp denna fil från en URL-adress",
        "action-writeapi": "använda skriv-API:t",
        "action-delete": "radera denna sida",
-       "action-deleterevision": "radera denna version",
-       "action-deletedhistory": "se denna sidas raderade historik",
+       "action-deleterevision": "radera sidversioner",
+       "action-deletelogentry": "radera loggposter",
+       "action-deletedhistory": "se en sidas raderade historik",
+       "action-deletedtext": "visa raderad sidversionstext",
        "action-browsearchive": "söka raderade sidor",
-       "action-undelete": "avradera denna sida",
-       "action-suppressrevision": "granska och återställa denna dolda version",
+       "action-undelete": "återställ sidor",
+       "action-suppressrevision": "granska och återställ dolda sidversioner",
        "action-suppressionlog": "se denna privata logg",
        "action-block": "blockera denna användare från redigering",
        "action-protect": "ändra skyddsnivå för denna sida",
        "action-userrights-interwiki": "ändra rättigheter för användare på andra wikier",
        "action-siteadmin": "låsa eller låsa upp databasen",
        "action-sendemail": "skicka e-post",
+       "action-editmyoptions": "redigera dina inställningar",
        "action-editmywatchlist": "redigera din bevakningslista",
        "action-viewmywatchlist": "visa din bevakningslista",
        "action-viewmyprivateinfo": "visa din privata information",
        "emailccsubject": "Kopia av ditt meddelande till $1: $2",
        "emailsent": "E-post har nu skickats",
        "emailsenttext": "Ditt e-postmeddelande har skickats",
-       "emailuserfooter": "Detta e-postmeddelande {{GENDER:$1|skickades}} av $1 till {{GENDER:$2|$2}} med funktionen \"{{int:emailuser}}\" på {{SITENAME}}.",
+       "emailuserfooter": "Detta e-postmeddelande {{GENDER:$1|skickades}} av $1 till {{GENDER:$2|$2}} med funktionen \"{{int:emailuser}}\" på {{SITENAME}}. {{GENDER:$2|Ditt}} e-postmeddelande kommer att skickas direkt till {{GENDER:$1|den ursprungliga avsändaren}}, vilket kommer avslöja {{GENDER:$2|din}} e-postadress för {{GENDER:$1|dem}}.",
        "usermessage-summary": "Lämnar systemmeddelande.",
        "usermessage-editor": "Systemmeddelare",
        "watchlist": "Bevakningslista",
        "mw-widgets-dateinput-no-date": "Inget valt datum",
        "mw-widgets-dateinput-placeholder-day": "ÅÅÅÅ-MM-DD",
        "mw-widgets-dateinput-placeholder-month": "ÅÅÅÅ-MM",
+       "mw-widgets-mediasearch-input-placeholder": "Sök efter media",
+       "mw-widgets-mediasearch-noresults": "Inga resultat hittades.",
        "mw-widgets-titleinput-description-new-page": "sidan existerar inte ännu",
        "mw-widgets-titleinput-description-redirect": "omdirigerar till $1",
        "mw-widgets-categoryselector-add-category-placeholder": "Lägg till en kategori...",
        "usercssispublic": "Observera: CSS-undersidor bör inte innehålla konfidentiella uppgifter eftersom de kan ses av andra användare.",
        "restrictionsfield-badip": "Ogiltig IP-adress eller intervall: $1",
        "restrictionsfield-label": "Tillåtna IP-intervall:",
-       "restrictionsfield-help": "En IP-adress eller CIDR-intervall per rad. För att aktivera allting, använd<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "En IP-adress eller CIDR-intervall per rad. För att aktivera allting, använd<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "pageid": "sid-ID $1"
 }
index 75b503c..9e0799e 100644 (file)
@@ -11,7 +11,8 @@
                        "Irus",
                        "Shklyaev",
                        "Wadorgurt",
-                       "Zpizza"
+                       "Zpizza",
+                       "Mouse21"
                ]
        },
        "tog-underline": "Чӧлсконъёсыз ултӥз гожен сызоно",
        "unprotectthispage": "Та бамлэсь утемзэ воштыны",
        "newpage": "Выль бам",
        "talkpage": "Та бам сярысь вераськыны",
-       "talkpagelinktext": "Ð\92ераськон",
+       "talkpagelinktext": "вераськон",
        "specialpage": "Ваньмыз панель",
        "personaltools": "Нимаз тӥрлыке",
        "articlepage": "Статьяез учкыны",
        "userlogout": "Потыны",
        "notloggedin": "Тон эн тусбуяськыны сӧзнэтэз",
        "userlogin-noaccount": "Ас учётной записьты ӧвӧл?",
+       "userlogin-joinproject": "Проектэ пыриськоно",
        "nologin": "Учётной книга ӧвӧл-а? $1.",
        "nologinlink": "Выль вики-авторлэн регистрациез",
        "createaccount": "выль вики-авторлэн регистрациез",
        "pt-userlogout": "Потыны",
        "oldpassword": "Вуж лушкемкыл:",
        "newpassword": "Выль лушкемкыл:",
+       "passwordreset": "Пароль куштыны",
        "passwordreset-username": "Пырон ним:",
        "italic_sample": "Бекырес текст",
        "italic_tip": "Бекырес текст",
        "showdiff": "Пыртэм воштонъёс",
        "anoneditwarning": "<strong>Сак луэ!</strong> Тӥ сайтэ ӧд пырелэ. Тӥ котькыӵе тупатонъёсыз лэсьтоды бере, тӥляд IP-адресты ваньмызлы адӟытӥськоз. Тӥ <strong>[$1 пыроды]</strong> яке <strong>[$2 учётной записез кылдытоды]</strong> бере, тӥляд тупатонъёсты герӟаськозы нимдылы, мукет пайдаосын ӵош.",
        "blockedtitle": "Заблокировать пыриськисьёс",
-       "blockedtext": "<strong>Ð\9aнигае Ñ\8fке Ñ\83Ñ\87Ñ\91Ñ\82ной IP-адÑ\80еÑ\81 Ð·Ð°Ð±Ð»Ð¾ÐºÐ¸Ñ\80ован.</strong>\n\nÐ\91локиÑ\80овка Ð°Ð´Ð¼Ð¸Ð½Ð¸Ñ\81Ñ\82Ñ\80аÑ\82оÑ\80 Ð¿Ð¾Ñ\82ӥз $1.\nÐ\92озÑ\8cмалÑ\8d Ð²Ñ\83оно Ð¼Ñ\83гез: \"\"$2\"\".\n\n* Ð\9aÑ\83Ñ\82Ñ\81кон Ð±Ð»Ð¾ÐºÐ¸Ñ\80овка: $8\n* Ð\91локиÑ\80овка Ð¾Ñ\80Ñ\82Ñ\87из: $6\n* Ð\91локиÑ\80овка Ð¼ÐµÑ\80еÑ\82Ñ\8aÑ\91Ñ\81Ñ\8bз: $7\n\nÐ\91Ñ\8bгаÑ\82Ó¥Ñ\81Ñ\8cкод-а Ñ\82он Ð³ÐµÑ\80Ó\9fаÑ\81Ñ\8cкемÑ\8bн $1 Ñ\8fке Ð¼Ñ\83кеÑ\82 ÐºÐ¾Ñ\82Ñ\8cкÑ\83дӥнÑ\8bз [[{{MediaWiki:Grouppage-sysop}}|админиÑ\81Ñ\82Ñ\80аÑ\82оÑ\80Ñ\8aÑ\91Ñ\81]], Ð±Ð»Ð¾ÐºÐ¸Ñ\80овка Ð¼ÐµÐ´ Ñ\8dÑ\81кеÑ\80озÑ\8b.\nУÑ\87ком, Ð¼Ð°Ñ\80 ÐºÑ\83Ñ\82Ñ\8bнÑ\8b Ñ\83г Ð±Ñ\8bгаÑ\82о Ñ\84Ñ\83нкÑ\86изÑ\8dÑ\81 \"гожÑ\82Ñ\8dÑ\82\", Ð°Ñ\81 ÐºÐµ [[Special:Preferences|наÑ\81Ñ\82Ñ\80ойка Ð¿ÐµÑ\80Ñ\81оналÑ\8cной]] Ð·Ñ\83Ñ\80каÑ\82Ó¥Ñ\81Ñ\8c Ñ\8fке Ñ\8dлекÑ\82Ñ\80онной Ð¿Ð¾Ñ\87Ñ\82аезлÑ\8dн Ð°Ð´Ñ\80еÑ\81Ñ\8dз Ñ\8dн Ñ\87Ñ\83Ñ\80Ñ\82на Ñ\83г ÐºÐ¾Ñ\80Ñ\80екÑ\82нÑ\8bй, Ñ\8fке Ð³Ð¾Ð¶Ñ\82Ó¥Ñ\81Ñ\8cкод ÐºÐµ, Ð³Ð¾Ð¶Ñ\82Ñ\8dÑ\82 Ñ\8bÑ\81Ñ\82он Ñ\83кÑ\88аÑ\81Ñ\8c Ð±Ð»Ð¾ÐºÐ¸Ñ\80овка Ð°Ð»Ð¾Ð½.\nТон IP-адÑ\80еÑ\81 â\80\94 $3, Ð±Ð»Ð¾ÐºÐ¸Ñ\80овка Ð¸Ð´ÐµÐ½Ñ\82иÑ\84икаÑ\82оÑ\80лÑ\8dн â\80\94 $5.\nÐ\9fожалÑ\83йÑ\81Ñ\82а, Ð°Ñ\81лÑ\8dÑ\81Ñ\8cÑ\82Ñ\8bм Ñ\82одон-Ñ\82а Ð²Ð°Ð·Ð¸Ñ\81Ñ\8cконÑ\8dз ÐºÐ¾Ñ\82Ñ\8cкÑ\83 Ð²Ð¾Ð·Ñ\8cмано.",
-       "autoblockedtext": "Тон IP-адрес, герӟет автоматически заблокирован а со, мар солэн кутыны луоно азьвыл кин ке но пырисьёс пӧлысь, заблокирован {{GENDER:$4|участник|куакеч}} $1. \nБлокировка возьмано луоз вуоно мугез:\n\n: \"$2\" - лы.\n\n* Кутскон блокировка: $8\n* Блокировка ортчиз: $6\n* Блокировка меретъёсыз: $7\n\nБыгатӥськод-а тон герӟаськемын $1 яке мукет котькудӥныз [[{{MediaWiki:Grouppage-sysop}}|администраторъёс]], блокировка мед эскерозы.\n\nУчком, мар кутыны уг быгато функцизэс \"гожтэт\", ас ке [[Special:Preferences|настройка персональной]] зуркатӥсь яке электронной почтаезлэн адресэз эн чуртна уг корректный, яке гожтӥськод ке, гожтэт ыстон укшась блокировка алон.\n\nТон IP-адрес — $3, блокировка идентификаторлэн — #$5.\nПожалуйста, аслэсьтым тодон-та вазиськонэз котьку возьмано.",
+       "blockedtext": "<strong>ТӥлÑ\8fд Ñ\83Ñ\87Ñ\91Ñ\82ной Ð·Ð°Ð¿Ð¸Ñ\81Ñ\8cÑ\82Ñ\8b Ñ\8fке IP-адÑ\80еÑ\81Ñ\82Ñ\8b Ð·Ð°Ð±Ð»Ð¾ÐºÐ¸Ñ\80оваÑ\82Ñ\8c ÐºÐ°Ñ\80емÑ\8bн Ð²Ð°Ð».</strong>\n\nÐ\91локиÑ\80овкаез Ð»Ñ\8dÑ\81Ñ\8cÑ\82ӥз $1.\nÐ\9fÑ\83Ñ\81Ñ\8aем Ð¼Ñ\83гез: <em>$2</em>.\n\n* Ð\91локиÑ\80овка ÐºÑ\83Ñ\82Ñ\81киз: $8\n* Ð\91локиÑ\80овка Ð¹Ñ\8bлпÑ\83мÑ\8aÑ\8fÑ\81Ñ\8cкоз: $6\n* Ð\91локиÑ\80овкалÑ\8dн Ñ\83жпÑ\83мез: $7\n\nТӥ Ð±Ð»Ð¾ÐºÐ¸Ñ\80овка Ñ\81Ñ\8fÑ\80Ñ\8bÑ\81Ñ\8c Ð²ÐµÑ\80аÑ\81Ñ\8cкÑ\8bнÑ\8b Ð±Ñ\8bгаÑ\82Ó¥Ñ\81Ñ\8cкодÑ\8b $1 Ñ\8fке ÐºÐ¾Ñ\82Ñ\8cкин Ð¼Ñ\83кеÑ\82 [[{{MediaWiki:Grouppage-sysop}}|админиÑ\81Ñ\82Ñ\80аÑ\82оÑ\80]] Ð´Ð¾Ñ\80Ñ\8b Ð³ÐµÑ\80Ó\9fаÑ\81Ñ\8cкÑ\8bÑ\81а.\n[[Special:Preferences|Ð\9dаÑ\81Ñ\82Ñ\80ойкаоÑ\81адÑ\8b]] Ñ\8dлекÑ\82Ñ\80он Ð¿Ð¾Ñ\87Ñ\82алÑ\8dн Ñ\83жаÑ\81Ñ\8c Ð°Ð´Ñ\80еÑ\81Ñ\8dз Ó§Ð²Ó§Ð» Ð´Ñ\8bÑ\80Ñ\8aÑ\8f, Ñ\82Ó¥ Â«Ð\92икиавÑ\82оÑ\80лÑ\8b Ð³Ð¾Ð¶Ñ\82Ñ\8dÑ\82» Ñ\84Ñ\83нкÑ\86иез Ñ\83же ÐºÑ\83Ñ\82Ñ\8bнÑ\8b Ñ\83д Ð±Ñ\8bгаÑ\82Ó¥Ñ\81Ñ\8cке, Ñ\81ое Ñ\82ӥленÑ\8bдÑ\8b Ñ\83же ÐºÑ\83Ñ\82он Ð´Ñ\83гдÑ\8bÑ\82Ñ\8dмÑ\8bн Ó§Ð²Ó§Ð» ÐºÐµ.\nТӥлÑ\8fд Ð°Ð»Ð¸ IP-адÑ\80еÑ\81Ñ\82Ñ\8b Ð»Ñ\83Ñ\8d $3, Ð½Ð¾ Ð±Ð»Ð¾ÐºÐ¸Ñ\80овка Ð¸Ð´ÐµÐ½Ñ\82иÑ\84икаÑ\82оÑ\80 â\80\94 #$5.\nТаÑ\83на Ð¿Ñ\8bÑ\80Ñ\82Ñ\8d Ð²Ð°Ð½Ñ\8c Ñ\82а Ð¿Ñ\8bÑ\80-поÑ\87 Ñ\81ведениоÑ\81Ñ\8bз Ð°Ñ\81Ñ\8cÑ\82Ñ\8dлÑ\8dн ÐºÑ\83Ñ\80онÑ\8aÑ\91Ñ\81адÑ\8b.",
+       "autoblockedtext": "Тӥляд IP-адресты автоматически заблокировать каремын вал, малы ке шуоно со кутӥськиз вал мукет викиавторен, кинзэ $1 заблокировать кариз.\nБлокировкалэн пусъем мугез:\n\n:<em>$2</em>\n\n* Блокировка кутскиз: $8\n* Блокировка йылпумъяськоз: $6\n* Блокировкалэн ужпумез: $7\n\nТӥ блокировка сярысь вераськыны быгатӥськоды $1 яке мукет [[{{MediaWiki:Grouppage-sysop}}|администраторъёс]] пӧлысь огез доры герӟаськыса.\n\nСак луэ, тӥ «Викиавторлы гожтэт» функциез уже кутыны уд быгатӥське [[Special:Preferences|асьтэлэн настройкаосады]] электрон почталэсь шонер адрессэ гожтытозь яке юнматытозь, либо блокировкады сыӵе амалэн гожтэтъёсыз ыстыны уг лэзьы ке.\n\nТӥляд али IP-адресты луэ $3, но блокировка идентификатор — #$5.\nТауна пыртэ вань та пыр-поч сведениосыз асьтэлэн куронъёсады.",
        "blockednoreason": "мугезлы эн возьмалэ",
        "whitelistedittext": "Тон кулэ $1 бам воштон понна.",
        "loginreqtitle": "Авторизация кулэ",
        "searchresults-title": "утчан \"$1\"",
        "prevn": "{{PLURAL:$1|$1-лы}} берлань",
        "nextn": "{{PLURAL:$1|$1-лы}} азьлань",
+       "nextn-title": "$1 {{PLURAL:$1|шедьтэмлы}} азьлань",
        "shown-title": "Адӟытылоно $1 {{PLURAL:$1|шедьтэмез}} бамлы быдэ",
        "viewprevnext": "Учкыны ($1 {{int:pipe-separator}} $2) ($3)",
        "searchmenu-new": "<strong>Кылдытыны «[[:$1]]» бамез та вики-проектын!</strong> {{PLURAL:$2|0=|Со сяна утчанэныды шедьтэм бамез учке.|Со сяна шедьтэм бамъёсты учке.}}",
        "prefs-editing": "Тупатон",
        "yourlanguage": "Интерфейслэн кылыз:",
        "prefs-preview": "Бамез эскерон",
-       "editusergroup": "Ð\93Ñ\80Ñ\83ппае {{GENDER:$1|пÑ\8bÑ\80иÑ\81Ñ\8c}} Ð¼Ñ\83кеÑ\82",
+       "editusergroup": "Ð\92икиавÑ\82оÑ\80лÑ\8dÑ\81Ñ\8c Ð³Ñ\80Ñ\83ппаоÑ\81Ñ\81Ñ\8d Ð²Ð¾Ð·Ñ\8cмаÑ\82Ñ\8bнÑ\8b",
        "group-autoconfirmed": "Автоподтвержденный пыриськисьёс",
        "group-bot": "Боты",
        "group-sysop": "Администраторъёс",
        "group-all": "(ваньзэ)",
+       "grouppage-sysop": "{{ns:project}}:Администраторъёс",
        "right-read": "лыдӟыны бам",
        "right-edit": "правка бам",
        "right-createpage": "бам кылдытон-а, уг-возьматэмзэ эскерон",
        "recentchanges-legend": "Выль тупатонъёслы настройкаос",
        "recentchanges-summary": "Та бамын викилэн дыръя радъям выль воштонъёсыз возьматэмын.",
        "recentchanges-label-newpage": "Та тупатонэн выль бам кылдӥз",
-       "recentchanges-label-minor": "Ð\9fичи воштон",
-       "recentchanges-label-bot": "Та Ñ\82Ñ\83паÑ\82онÑ\8dз ÐºÐ°Ñ\80из Ð±Ð¾Ñ\82",
+       "recentchanges-label-minor": "Та Ñ\82Ñ\83паÑ\82он Ð»Ñ\83Ñ\8d Ð¿ичи воштон",
+       "recentchanges-label-bot": "Та Ñ\82Ñ\83паÑ\82онÑ\8dз Ð±Ð¾Ñ\82 ÐºÐ°Ñ\80из",
        "recentchanges-label-unpatrolled": "Та тупатонэз нокин но ӧз эскеры на",
        "recentchanges-label-plusminus": "Бамлэн быдӟалаез сомында байтъёслы воштӥськиз",
        "recentchanges-legend-heading": "<strong>Легенда:</strong>",
        "rollbacklinkcount": "$1 {{PLURAL:$1|тупатонэз}} ӝог берыктыны",
        "revertpage": "Откат шонертон [[Special:Contributions/$2|$2]] ([[User talk:$2|обсуждение]]) доры версия [[User:$1|$1]]",
        "revertpage-nouser": "Откат шонертон (пыриськисьёс ватэм нимъёссы) доры версия {{GENDER:$1|[[User:$1|$1]]}}",
+       "protectlogpage": "Утёнъёсын журнал",
        "restriction-edit": "Тупатон",
        "undeletehistory": "Выльысь ке тон бамъёстэ, выльысь историяз луэм воштӥськонъёс вань.\nБӧрысь кылдӥзы выль бамъёс палэнэ кошконо луэ ке, сыӵе ик нимыз, историяз вошъяськонъёс предшествующий выльысь кылдозы.",
        "undeletehistorynoadmin": "Статьяос палэнтэмын вал. Мугез но палэнэ список пыриды, со статьяе редактировать-озь палэнэгес, зӧк возьматэ. Текст статьяез удаленный администраторъёс гинэ учкыны быгатод.",
        "whatlinkshere-prev": "{{PLURAL:$1|берлань|$1-лы берлань}}",
        "whatlinkshere-next": "{{PLURAL:$1|азьлань|$1-лы азьлань}}",
        "whatlinkshere-links": "← чӧлсконъёс",
+       "whatlinkshere-hideredirs": "$1 ыстӥсь бамъёсты",
        "whatlinkshere-hidetrans": "$1 пыртонъёсты",
        "whatlinkshere-hidelinks": "$1 чӧлсконъёсты",
        "whatlinkshere-filters": "Фильтръёс",
        "block": "Блокировка пыриськисьёс",
        "blockip": "Заблокировать {{GENDER:$1|пыриськисьёс}}",
        "ipbreason-dropdown": "* Блокировка мугез кабес\n** Полы информациез оскизы\n** Вордскем палэнэ бам\n** Спам-сайтъя педпал чӧлскон\n** Текстлэсь визьем ватсан/жуг-жаг\n** Кышкытлыклэсь, пыриськыны уйиськон\n** Злоупотребление кӧня ке книга учётной\n** Пыриськисьёслэн нимъёссы пыриськисьёс",
-       "ipboptions": "2 Ñ\87аÑ\81:2 hours,1 Ð½Ñ\83наллÑ\8b:1 day,3 Ð½Ñ\83наллÑ\8b:3 days,1 Ð°Ñ\80нÑ\8fезлÑ\8b:1 week,2 Ð°Ñ\80нÑ\8fÑ\8fз:2 weeks,1 Ñ\82олÑ\8dзÑ\8c:1 month,3 Ñ\82олÑ\8dзÑ\8c:3 months,6 Ñ\82олÑ\8dзÑ\8c:6 months,1 Ð°Ñ\80лÑ\8dн:1 year,беÑ\81Ñ\81Ñ\80оÑ\87но:infinite",
+       "ipboptions": "2 Ñ\87аÑ\81:2 hours,1 Ð½Ñ\83наллÑ\8b:1 day,3 Ð½Ñ\83наллÑ\8b:3 days,1 Ð°Ñ\80нÑ\8fезлÑ\8b:1 week,2 Ð°Ñ\80нÑ\8fÑ\8fз:2 weeks,1 Ñ\82олÑ\8dзÑ\8c:1 month,3 Ñ\82олÑ\8dзÑ\8c:3 months,6 Ñ\82олÑ\8dзÑ\8c:6 months,1 Ð°Ñ\80лÑ\8dн:1 year,нокÑ\83:infinite",
        "unblocked": "[[User:$1|$1]] разблокировать",
        "unblocked-id": "Блокировка $1 басьтоно луиз",
        "blocklist-target": "Ужпумъёс",
        "blocklist-reason": "Мугез",
-       "infiniteblock": "беÑ\81Ñ\81Ñ\80оÑ\87но",
+       "infiniteblock": "нокÑ\83",
        "expiringblock": "йылпумъяськиз $1-ысь $2",
        "anononlyblock": "аноним гинэ",
        "noautoblockblock": "disconnect автоблокировка",
        "unblocklink": "разблокировать",
        "change-blocklink": "блокировка воштыны",
        "contribslink": "тупатонъёсыз",
-       "autoblocker": "Автоблокировка-со понна, мае тӥ IP-адрес кутыны али \"[[User:$1|$1]]\". \nБлокировка мугез $1: \"$2\"",
+       "autoblocker": "Автоблокировка, малы ке шуоно «[[User:$1|$1]]» тӥлесьтыд IP-адрестэс алигес уже кутӥз.\n$1 блокировкалэн мугез: «$2»",
        "blocklogentry": "заблокировать [[$1]] дыр $2 $3",
        "reblock-logentry": "блокировка воштӥз [[$1]] дыр $2 $3",
        "blocklogtext": "Блокировка но та журналлэн ужезлы разблокирование пользователь.\nЗаблокировать Автоматически IP-адрес уг возьма.\nПроизведениосыз печатласько эстониын [[Special:BlockList|сьӧд списокын]], бан список блокъёс лэсьтыны.",
index c6a38a4..09b96e6 100644 (file)
        "userrights-user-editname": "输入用户名:",
        "editusergroup": "加载用户组",
        "editinguser": "更改{{GENDER:$1|用户}}<strong>[[User:$1|$1]]</strong>的用户权限$2",
+       "viewinguserrights": "查看{{GENDER:$1|用户}}<strong>[[User:$1|$1]]</strong>的用户权限$2",
        "userrights-editusergroup": "编辑用户组",
+       "userrights-viewusergroup": "查看用户组",
        "saveusergroups": "保存{{GENDER:$1|用户}}组",
        "userrights-groupsmember": "用户组:",
        "userrights-groupsmember-auto": "自动用户组:",
        "action-upload_by_url": "从URL上传本文件",
        "action-writeapi": "使用写入API",
        "action-delete": "删除本页",
-       "action-deleterevision": "删除本版本",
-       "action-deletedhistory": "查看本页面被删除的历史",
+       "action-deleterevision": "删除修订",
+       "action-deletelogentry": "删除日志记录",
+       "action-deletedhistory": "查看页面被删除的历史",
+       "action-deletedtext": "查看已删除的修订版本文字",
        "action-browsearchive": "搜索已被删除的页面",
-       "action-undelete": "还原本页",
-       "action-suppressrevision": "复核并还原该隐藏版本",
+       "action-undelete": "还原页面",
+       "action-suppressrevision": "复核并还原隐藏修订版本",
        "action-suppressionlog": "查看本非公开日志",
        "action-block": "阻止该用户编辑",
        "action-protect": "更改本页面的保护级别",
        "action-userrights-interwiki": "编辑其他wiki用户的用户权限",
        "action-siteadmin": "锁定或解锁数据库",
        "action-sendemail": "发送电子邮件",
+       "action-editmyoptions": "编辑您的参数设置",
        "action-editmywatchlist": "编辑您的监视列表",
        "action-viewmywatchlist": "查看您的监视列表",
        "action-viewmyprivateinfo": "查看您的私人信息",
        "emailccsubject": "您发送给$1的消息的副本:$2",
        "emailsent": "电子邮件已发送",
        "emailsenttext": "您的电子邮件已经发出。",
-       "emailuserfooter": "本电子邮件是通过{{SITENAME}}的“{{int:emailuser}}”功能被$1{{GENDER:$1|发送}}至{{GENDER:$2|$2}}的。",
+       "emailuserfooter": "本电子邮件是通过{{SITENAME}}的“{{int:emailuser}}”功能被$1{{GENDER:$1|发送}}至{{GENDER:$2|$2}}的。{{GENDER:$2|您}}的电子邮件将直接发送至{{GENDER:$1|原始发送者}},并向{{GENDER:$1|其}}显示{{GENDER:$2|您}}的电子邮件地址。",
        "usermessage-summary": "留下系统消息。",
        "usermessage-editor": "系统信息编辑器",
        "watchlist": "监视列表",
        "confirm-rollback-button": "确定",
        "confirm-rollback-top": "回退此页面的编辑么?",
        "semicolon-separator": ";",
-       "comma-separator": "",
+       "comma-separator": "",
        "colon-separator": ":",
        "pipe-separator": "&#32;|&#32;",
        "word-separator": "",
        "usercssispublic": "请注意:CSS子页面不应包含机密数据,因为它们可以被其他用户查看。",
        "restrictionsfield-badip": "无效的IP地址或段:$1",
        "restrictionsfield-label": "允许的IP段:",
-       "restrictionsfield-help": "每行一个IP地址或CIDR段。要启用所有,可使用<br><code>0.0.0.0/0</code><br><code>::/0</code>"
+       "restrictionsfield-help": "每行一个IP地址或CIDR段。要启用所有,可使用<br><code>0.0.0.0/0</code><br><code>::/0</code>",
+       "pageid": "页面ID$1"
 }
index e2025e0..f702115 100644 (file)
        "confirm-rollback-button": "確定",
        "confirm-rollback-top": "還原編輯到此頁面?",
        "semicolon-separator": ";",
-       "comma-separator": "",
+       "comma-separator": "",
        "colon-separator": ":",
        "word-separator": "",
        "parentheses": " ($1)",
index 38daf64..18c7f11 100644 (file)
@@ -60,7 +60,7 @@ class BackupDumper extends Maintenance {
        /**
         * The dependency-injected database to use.
         *
-        * @var DatabaseBase|null
+        * @var IDatabase|null
         *
         * @see self::setDB
         */
@@ -314,7 +314,7 @@ class BackupDumper extends Maintenance {
         * @todo Fixme: the --server parameter is currently not respected, as it
         * doesn't seem terribly easy to ask the load balancer for a particular
         * connection by name.
-        * @return DatabaseBase
+        * @return IDatabase
         */
        function backupDb() {
                if ( $this->forcedDb !== null ) {
@@ -335,7 +335,7 @@ class BackupDumper extends Maintenance {
         * Force the dump to use the provided database connection for database
         * operations, wherever possible.
         *
-        * @param DatabaseBase|null $db (Optional) the database connection to use. If null, resort to
+        * @param IDatabase|null $db (Optional) the database connection to use. If null, resort to
         *   use the globally provided ways to get database connections.
         */
        function setDB( IDatabase $db = null ) {
index 8618a93..dee2164 100644 (file)
 馬鞌 马鞍
 觔斗 斤斗
 穀阳 穀阳
+伊東豊雄   伊东丰雄
index 3062c1e..3c7ea7a 100644 (file)
 划進 划進
 划過 划過
 划龍舟      划龍舟
+划龍船      划龍船
 只影響      只影響
 么弟 么弟
 六么 六么
 苧麻 苧麻
 张柏芝      張栢芝
 杜琪峰      杜琪峯
+單向 單向
+轉向 轉向 #分詞用
index dd38a30..b4cd628 100644 (file)
 碼錶
 錶冠
 魔錶
-彆口氣
-彆強
-皺彆
-一彆頭
 并州
 幽并
 併力
 於後
 猜三划五
 划龍舟
+划龍船
 南迴線
 南迴鐵路
 北迴線
 藉此
 龍捲
 捲舌
+不捲
+漫捲
+捲地
+捲瓣
+捲葉蛾
+捲尾猴
+捲積雲
 夸父
 夸克
 夸特
 水里溪
 二里頭
 年歷史
+年歷次
 西歷史
+西歷次
+西歷代
+西歷任
 國歷史
 國歷代
 國歷任
 不斗膽
 不每只
 不采聲
-專向往
+向往常
+向往日
+向往時
+向往來
+方向
+轉向
+單向 #分詞用
 丰容
 之一只
 之二只
 網球台
 合府上
 後面店
-向往常
-向往日
-向往時
-向往來
 唯一只
 喂了一聲
-喜向往
 四出徵收
 四面包
 多半只
 扎好根
 扑撻
 打吨
-折向往
 拉面上
 拉面具
 拉面前
 敢情欲
 敢斗了膽
 敲扑
-方向往
 望了望
 桌几
 每每只
 要自制
 語有云
 跌扑
-轉向往
 酒帘
 金表態
 金表情
 幸運鬍
 刮鬍
 剃鬍
-吹鬍
 蓄鬍
-白鬍
-長鬍
 鬍髯
 髯鬍
 髭鬍
 功勳
 蝎虎
 磨蝎
-方志恒
 古蹟
 瀋撫
 賦范
 乃係
 製衣
 巨製
-不捲
-漫捲
-捲地
-捲葉蛾
-捲尾猴
-捲積雲
 窗簾
 吉徵
 凶徵
 譯製
 燉製
 煮製
+熬製
 遏制 #以下分詞用
 管制
 抑制
 繫上,
 繫上。
 繫舟
+繫膜
 亂發生
 亂發脾氣
 秀發村
 啊喂
 呵喂
 呦喂
+哈囉喂
 松口鎮
+岩松了
 沙瑯
 琺瑯
 菜餚
 仁貴 #分詞用
 金聖歎
 天台 #分詞用
+性別扭曲
index b9baf8c..9906990 100644 (file)
@@ -2,73 +2,22 @@
 
 require_once __DIR__ . '/Maintenance.php';
 
-use Composer\Spdx\SpdxLicenses;
-use JsonSchema\Validator;
-
 class ValidateRegistrationFile extends Maintenance {
        public function __construct() {
                parent::__construct();
                $this->addArg( 'path', 'Path to extension.json/skin.json file.', true );
        }
        public function execute() {
-               if ( !class_exists( Validator::class ) ) {
-                       $this->error( 'The JsonSchema library cannot be found, please install it through composer.', 1 );
-               } elseif ( !class_exists( SpdxLicenses::class ) ) {
-                       $this->error(
-                               'The spdx-licenses library cannot be found, please install it through composer.', 1
-                       );
-               }
-
+               $validator = new ExtensionJsonValidator( function( $msg ) {
+                       $this->error( $msg, 1 );
+               } );
+               $validator->checkDependencies();
                $path = $this->getArg( 0 );
-               $data = json_decode( file_get_contents( $path ) );
-               if ( !is_object( $data ) ) {
-                       $this->error( "$path is not a valid JSON file.", 1 );
-               }
-               if ( !isset( $data->manifest_version ) ) {
-                       $this->output( "Warning: No manifest_version set, assuming 1.\n" );
-                       // For backwards-compatability assume 1
-                       $data->manifest_version = 1;
-               }
-               $version = $data->manifest_version;
-               if ( $version !== ExtensionRegistry::MANIFEST_VERSION ) {
-                       $schemaPath = dirname( __DIR__ ) . "/docs/extension.schema.v$version.json";
-               } else {
-                       $schemaPath = dirname( __DIR__ ) . '/docs/extension.schema.json';
-               }
-
-               if ( $version < ExtensionRegistry::OLDEST_MANIFEST_VERSION
-                       || $version > ExtensionRegistry::MANIFEST_VERSION
-               ) {
-                       $this->error( "Error: $path is using a non-supported schema version, it should use "
-                               . ExtensionRegistry::MANIFEST_VERSION, 1 );
-               } elseif ( $version < ExtensionRegistry::MANIFEST_VERSION ) {
-                       $this->output( "Warning: $path is using a deprecated schema, and should be updated to "
-                               . ExtensionRegistry::MANIFEST_VERSION . "\n" );
-               }
-
-               $licenseError = false;
-               // Check if it's a string, if not, schema validation will display an error
-               if ( isset( $data->{'license-name'} ) && is_string( $data->{'license-name'} ) ) {
-                       $licenses = new SpdxLicenses();
-                       $valid = $licenses->validate( $data->{'license-name'} );
-                       if ( !$valid ) {
-                               $licenseError = '[license-name] Invalid SPDX license identifier, '
-                                       . 'see <https://spdx.org/licenses/>';
-                       }
-               }
-
-               $validator = new Validator;
-               $validator->check( $data, (object)[ '$ref' => 'file://' . $schemaPath ] );
-               if ( $validator->isValid() && !$licenseError ) {
-                       $this->output( "$path validates against the version $version schema!\n" );
-               } else {
-                       foreach ( $validator->getErrors() as $error ) {
-                               $this->output( "[{$error['property']}] {$error['message']}\n" );
-                       }
-                       if ( $licenseError ) {
-                               $this->output( "$licenseError\n" );
-                       }
-                       $this->error( "$path does not validate.", 1 );
+               try {
+                       $validator->validate( $path );
+                       $this->output( "$path validates against the schema!\n" );
+               } catch ( ExtensionJsonValidationError $e ) {
+                       $this->error( $e->getMessage(), 1 );
                }
        }
 }
index a96ae13..1acedf2 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:37Z
+ * Date: 2016-12-06T23:32:53Z
  */
 ( function ( OO ) {
 
index e5e6252..72df673 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:42Z
+ * Date: 2016-12-06T23:32:57Z
  */
 .oo-ui-element-hidden {
   display: none !important;
@@ -832,10 +832,14 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
   display: none;
 }
 .oo-ui-textInputWidget.oo-ui-iconElement > .oo-ui-iconElement-icon,
-.oo-ui-textInputWidget.oo-ui-indicatorElement > .oo-ui-indicatorElement-indicator {
+.oo-ui-textInputWidget.oo-ui-indicatorElement > .oo-ui-indicatorElement-indicator,
+.oo-ui-textInputWidget > .oo-ui-labelElement-label {
   display: block;
   position: absolute;
   top: 0;
+}
+.oo-ui-textInputWidget.oo-ui-iconElement > .oo-ui-iconElement-icon,
+.oo-ui-textInputWidget.oo-ui-indicatorElement > .oo-ui-indicatorElement-indicator {
   height: 100%;
   -webkit-touch-callout: none;
   -webkit-user-select: none;
@@ -843,21 +847,24 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
       -ms-user-select: none;
           user-select: none;
 }
+.oo-ui-textInputWidget > .oo-ui-iconElement-icon,
+.oo-ui-textInputWidget-labelPosition-before > .oo-ui-labelElement-label {
+  left: 0;
+}
+.oo-ui-textInputWidget > .oo-ui-indicatorElement-indicator,
+.oo-ui-textInputWidget-labelPosition-after > .oo-ui-labelElement-label {
+  right: 0;
+}
 .oo-ui-textInputWidget.oo-ui-widget-enabled > .oo-ui-iconElement-icon,
-.oo-ui-textInputWidget.oo-ui-widget-enabled > .oo-ui-indicatorElement-indicator {
+.oo-ui-textInputWidget.oo-ui-widget-enabled > .oo-ui-indicatorElement-indicator,
+.oo-ui-textInputWidget.oo-ui-widget-enabled > .oo-ui-labelElement-label {
   cursor: text;
 }
 .oo-ui-textInputWidget.oo-ui-widget-enabled.oo-ui-textInputWidget-type-search > .oo-ui-indicatorElement-indicator {
   cursor: pointer;
 }
 .oo-ui-textInputWidget.oo-ui-widget-disabled input,
-.oo-ui-textInputWidget.oo-ui-widget-disabled textarea {
-  -webkit-touch-callout: none;
-  -webkit-user-select: none;
-     -moz-user-select: none;
-      -ms-user-select: none;
-          user-select: none;
-}
+.oo-ui-textInputWidget.oo-ui-widget-disabled textarea,
 .oo-ui-textInputWidget.oo-ui-widget-disabled .oo-ui-labelElement-label {
   -webkit-touch-callout: none;
   -webkit-user-select: none;
@@ -865,21 +872,6 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
       -ms-user-select: none;
           user-select: none;
 }
-.oo-ui-textInputWidget.oo-ui-labelElement > .oo-ui-labelElement-label {
-  display: block;
-}
-.oo-ui-textInputWidget > .oo-ui-iconElement-icon,
-.oo-ui-textInputWidget-labelPosition-before > .oo-ui-labelElement-label {
-  left: 0;
-}
-.oo-ui-textInputWidget > .oo-ui-indicatorElement-indicator,
-.oo-ui-textInputWidget-labelPosition-after > .oo-ui-labelElement-label {
-  right: 0;
-}
-.oo-ui-textInputWidget > .oo-ui-labelElement-label {
-  position: absolute;
-  top: 0;
-}
 .oo-ui-textInputWidget input,
 .oo-ui-textInputWidget textarea {
   padding: 0.5em;
index 6a31fe8..bab34b8 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:42Z
+ * Date: 2016-12-06T23:32:57Z
  */
 .oo-ui-element-hidden {
   display: none !important;
 .oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-buttonElement-pressed > input.oo-ui-buttonElement-button,
 .oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-buttonElement-pressed > .oo-ui-buttonElement-button:active {
   color: #000;
+  box-shadow: none;
 }
 .oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-flaggedElement-progressive > .oo-ui-buttonElement-button > .oo-ui-labelElement-label {
   color: #36c;
   color: #447ff5;
 }
 .oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-flaggedElement-progressive > .oo-ui-buttonElement-button:active > .oo-ui-labelElement-label,
+.oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-flaggedElement-progressive > .oo-ui-buttonElement-button:active:focus > .oo-ui-labelElement-label,
 .oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-flaggedElement-progressive.oo-ui-buttonElement-pressed > .oo-ui-buttonElement-button > .oo-ui-labelElement-label {
   color: #2a4b8d;
   box-shadow: none;
   color: #447ff5;
 }
 .oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-flaggedElement-constructive > .oo-ui-buttonElement-button:active > .oo-ui-labelElement-label,
+.oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-flaggedElement-constructive > .oo-ui-buttonElement-button:active:focus > .oo-ui-labelElement-label,
 .oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-flaggedElement-constructive.oo-ui-buttonElement-pressed > .oo-ui-buttonElement-button > .oo-ui-labelElement-label {
   color: #2a4b8d;
   box-shadow: none;
   color: #ff4242;
 }
 .oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-flaggedElement-destructive > .oo-ui-buttonElement-button:active > .oo-ui-labelElement-label,
+.oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-flaggedElement-destructive > .oo-ui-buttonElement-button:active:focus > .oo-ui-labelElement-label,
 .oo-ui-buttonElement-frameless.oo-ui-widget-enabled.oo-ui-flaggedElement-destructive.oo-ui-buttonElement-pressed > .oo-ui-buttonElement-button > .oo-ui-labelElement-label {
   color: #b32424;
   box-shadow: none;
   box-shadow: inset 0 0 0 1px #36c;
 }
 .oo-ui-buttonElement-framed.oo-ui-widget-enabled > .oo-ui-buttonElement-button:active,
+.oo-ui-buttonElement-framed.oo-ui-widget-enabled > .oo-ui-buttonElement-button:active:focus,
 .oo-ui-buttonElement-framed.oo-ui-widget-enabled.oo-ui-buttonElement-pressed > .oo-ui-buttonElement-button {
   background-color: #c8ccd1;
   color: #000;
   border-color: #72777d;
+  box-shadow: none;
 }
 .oo-ui-buttonElement-framed.oo-ui-widget-enabled.oo-ui-buttonElement-active > .oo-ui-buttonElement-button {
   background-color: #2a4b8d;
@@ -882,7 +888,7 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
 }
 .oo-ui-checkboxInputWidget {
   position: relative;
-  line-height: 1.6em;
+  line-height: 1.5625em;
   white-space: nowrap;
 }
 .oo-ui-checkboxInputWidget * {
@@ -892,8 +898,8 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
 .oo-ui-checkboxInputWidget [type='checkbox'] {
   position: relative;
   max-width: none;
-  width: 1.6em;
-  height: 1.6em;
+  width: 1.5625em;
+  height: 1.5625em;
   margin: 0;
   opacity: 0;
   z-index: 1;
@@ -909,8 +915,8 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
           box-sizing: border-box;
   position: absolute;
   left: 0;
-  width: 1.6em;
-  height: 1.6em;
+  width: 1.5625em;
+  height: 1.5625em;
   border: 1px solid #72777d;
   border-radius: 2px;
 }
@@ -1032,7 +1038,7 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
 }
 .oo-ui-radioInputWidget {
   position: relative;
-  line-height: 1.6em;
+  line-height: 1.5625em;
   white-space: nowrap;
 }
 .oo-ui-radioInputWidget * {
@@ -1042,8 +1048,8 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
 .oo-ui-radioInputWidget [type='radio'] {
   position: relative;
   max-width: none;
-  width: 1.6em;
-  height: 1.6em;
+  width: 1.5625em;
+  height: 1.5625em;
   margin: 0;
   opacity: 0;
   z-index: 1;
@@ -1055,8 +1061,8 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
   -webkit-box-sizing: border-box;
      -moz-box-sizing: border-box;
           box-sizing: border-box;
-  width: 1.6em;
-  height: 1.6em;
+  width: 1.5625em;
+  height: 1.5625em;
   border: 1px solid #72777d;
   border-radius: 100%;
 }
@@ -1071,11 +1077,11 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
   border-radius: 100%;
 }
 .oo-ui-radioInputWidget [type='radio']:checked + span {
-  border-width: 0.4em;
+  border-width: 0.390625em;
 }
 .oo-ui-radioInputWidget [type='radio']:checked:hover + span,
 .oo-ui-radioInputWidget [type='radio']:checked:focus:hover + span {
-  border-width: 0.4em;
+  border-width: 0.390625em;
 }
 .oo-ui-radioInputWidget [type='radio']:disabled + span {
   background-color: #c8ccd1;
@@ -1183,10 +1189,14 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
   display: none;
 }
 .oo-ui-textInputWidget.oo-ui-iconElement > .oo-ui-iconElement-icon,
-.oo-ui-textInputWidget.oo-ui-indicatorElement > .oo-ui-indicatorElement-indicator {
+.oo-ui-textInputWidget.oo-ui-indicatorElement > .oo-ui-indicatorElement-indicator,
+.oo-ui-textInputWidget > .oo-ui-labelElement-label {
   display: block;
   position: absolute;
   top: 0;
+}
+.oo-ui-textInputWidget.oo-ui-iconElement > .oo-ui-iconElement-icon,
+.oo-ui-textInputWidget.oo-ui-indicatorElement > .oo-ui-indicatorElement-indicator {
   height: 100%;
   -webkit-touch-callout: none;
   -webkit-user-select: none;
@@ -1194,21 +1204,24 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
       -ms-user-select: none;
           user-select: none;
 }
+.oo-ui-textInputWidget > .oo-ui-iconElement-icon,
+.oo-ui-textInputWidget-labelPosition-before > .oo-ui-labelElement-label {
+  left: 0;
+}
+.oo-ui-textInputWidget > .oo-ui-indicatorElement-indicator,
+.oo-ui-textInputWidget-labelPosition-after > .oo-ui-labelElement-label {
+  right: 0;
+}
 .oo-ui-textInputWidget.oo-ui-widget-enabled > .oo-ui-iconElement-icon,
-.oo-ui-textInputWidget.oo-ui-widget-enabled > .oo-ui-indicatorElement-indicator {
+.oo-ui-textInputWidget.oo-ui-widget-enabled > .oo-ui-indicatorElement-indicator,
+.oo-ui-textInputWidget.oo-ui-widget-enabled > .oo-ui-labelElement-label {
   cursor: text;
 }
 .oo-ui-textInputWidget.oo-ui-widget-enabled.oo-ui-textInputWidget-type-search > .oo-ui-indicatorElement-indicator {
   cursor: pointer;
 }
 .oo-ui-textInputWidget.oo-ui-widget-disabled input,
-.oo-ui-textInputWidget.oo-ui-widget-disabled textarea {
-  -webkit-touch-callout: none;
-  -webkit-user-select: none;
-     -moz-user-select: none;
-      -ms-user-select: none;
-          user-select: none;
-}
+.oo-ui-textInputWidget.oo-ui-widget-disabled textarea,
 .oo-ui-textInputWidget.oo-ui-widget-disabled .oo-ui-labelElement-label {
   -webkit-touch-callout: none;
   -webkit-user-select: none;
@@ -1216,37 +1229,22 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
       -ms-user-select: none;
           user-select: none;
 }
-.oo-ui-textInputWidget.oo-ui-labelElement > .oo-ui-labelElement-label {
-  display: block;
-}
-.oo-ui-textInputWidget > .oo-ui-iconElement-icon,
-.oo-ui-textInputWidget-labelPosition-before > .oo-ui-labelElement-label {
-  left: 0;
-}
-.oo-ui-textInputWidget > .oo-ui-indicatorElement-indicator,
-.oo-ui-textInputWidget-labelPosition-after > .oo-ui-labelElement-label {
-  right: 0;
-}
-.oo-ui-textInputWidget > .oo-ui-labelElement-label {
-  position: absolute;
-  top: 0;
-}
 .oo-ui-textInputWidget input,
 .oo-ui-textInputWidget textarea {
-  margin: 0;
   font-size: inherit;
   font-family: inherit;
   background-color: #fff;
   color: #000;
   border: 1px solid #a2a9b1;
   border-radius: 2px;
-  padding: 0.625em 0.546875em 0.546875em;
 }
 .oo-ui-textInputWidget input {
+  padding: 0.625em 0.546875em 0.546875em;
   line-height: 1.172em;
 }
 .oo-ui-textInputWidget textarea {
-  line-height: 1.275;
+  padding: 0.46875em 0.546875em 0.546875em;
+  line-height: 1.4;
 }
 .oo-ui-textInputWidget .oo-ui-pendingElement-pending {
   background-color: transparent;
@@ -1311,51 +1309,50 @@ body:not( :-moz-handler-blocked ) .oo-ui-fieldsetLayout {
   border-color: #f00;
   box-shadow: inset 0 0 0 0.1em #f00;
 }
-.oo-ui-textInputWidget.oo-ui-widget-disabled input,
-.oo-ui-textInputWidget.oo-ui-widget-disabled textarea {
-  background-color: #eaecf0;
-  color: #72777d;
-  text-shadow: 0 1px 1px #fff;
-  border-color: #c8ccd1;
-}
-.oo-ui-textInputWidget.oo-ui-widget-disabled .oo-ui-iconElement-icon,
-.oo-ui-textInputWidget.oo-ui-widget-disabled .oo-ui-indicatorElement-indicator {
-  opacity: 0.51;
-}
-.oo-ui-textInputWidget.oo-ui-widget-disabled .oo-ui-labelElement-label {
-  color: #72777d;
-  text-shadow: 0 1px 1px #fff;
-}
 .oo-ui-textInputWidget.oo-ui-iconElement input,
 .oo-ui-textInputWidget.oo-ui-iconElement textarea {
-  padding-left: 2.875em;
+  padding-left: 2.65625em;
 }
 .oo-ui-textInputWidget.oo-ui-iconElement .oo-ui-iconElement-icon {
-  left: 0;
-  height: 100%;
-  max-height: 2.375em;
-  margin-left: 0.5em;
-  background-position: right center;
+  max-height: 2.5em;
+  left: 0.46875em;
 }
 .oo-ui-textInputWidget.oo-ui-indicatorElement input,
 .oo-ui-textInputWidget.oo-ui-indicatorElement textarea {
   padding-right: 2.4875em;
 }
 .oo-ui-textInputWidget.oo-ui-indicatorElement .oo-ui-indicatorElement-indicator {
-  height: 100%;
-  max-height: 2.375em;
-  margin: 0 0.775em;
+  max-height: 2.5em;
+  right: 0.625em;
 }
 .oo-ui-textInputWidget > .oo-ui-labelElement-label {
   color: #72777d;
-  padding: 0.4em;
-  line-height: 1.5;
+  right: 0.625em;
+  border: 1px solid transparent;
+  border-width: 1px 0;
+  padding: 0.625em 0 0.546875em;
+  line-height: 1.172em;
 }
 .oo-ui-textInputWidget-labelPosition-after.oo-ui-indicatorElement > .oo-ui-labelElement-label {
-  margin-right: 2.0875em;
+  right: 2.1875em;
 }
 .oo-ui-textInputWidget-labelPosition-before.oo-ui-iconElement > .oo-ui-labelElement-label {
-  margin-left: 2.475em;
+  left: 2.65625em;
+}
+.oo-ui-textInputWidget.oo-ui-widget-disabled input,
+.oo-ui-textInputWidget.oo-ui-widget-disabled textarea {
+  background-color: #eaecf0;
+  color: #72777d;
+  text-shadow: 0 1px 1px #fff;
+  border-color: #c8ccd1;
+}
+.oo-ui-textInputWidget.oo-ui-widget-disabled .oo-ui-iconElement-icon,
+.oo-ui-textInputWidget.oo-ui-widget-disabled .oo-ui-indicatorElement-indicator {
+  opacity: 0.51;
+}
+.oo-ui-textInputWidget.oo-ui-widget-disabled .oo-ui-labelElement-label {
+  color: #72777d;
+  text-shadow: 0 1px 1px #fff;
 }
 .oo-ui-menuSelectWidget {
   position: absolute;
index c53470e..b92094c 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:37Z
+ * Date: 2016-12-06T23:32:53Z
  */
 ( function ( OO ) {
 
index 962db9a..7dc6bef 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:37Z
+ * Date: 2016-12-06T23:32:53Z
  */
 ( function ( OO ) {
 
index 4b59876..baf8833 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:42Z
+ * Date: 2016-12-06T23:32:57Z
  */
 .oo-ui-popupTool .oo-ui-popupWidget-popup,
 .oo-ui-popupTool .oo-ui-popupWidget-anchor {
index c3b0c98..99a1f5e 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:42Z
+ * Date: 2016-12-06T23:32:57Z
  */
 .oo-ui-tool.oo-ui-widget-enabled {
   -webkit-transition: background-color 100ms;
index f57e2db..e45ca29 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:37Z
+ * Date: 2016-12-06T23:32:53Z
  */
 ( function ( OO ) {
 
index 884e48e..318bf82 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:42Z
+ * Date: 2016-12-06T23:32:57Z
  */
 .oo-ui-draggableElement-handle,
 .oo-ui-draggableElement-handle.oo-ui-widget {
index cfbea3e..a4db2a3 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:42Z
+ * Date: 2016-12-06T23:32:57Z
  */
 .oo-ui-draggableElement-handle,
 .oo-ui-draggableElement-handle.oo-ui-widget {
index 8242c86..1185fc1 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:37Z
+ * Date: 2016-12-06T23:32:53Z
  */
 ( function ( OO ) {
 
index 40de1d7..ad0e7ab 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:42Z
+ * Date: 2016-12-06T23:32:57Z
  */
 .oo-ui-actionWidget.oo-ui-pendingElement-pending {
   background-image: /* @embed */ url(themes/apex/images/textures/pending.gif);
index d1b35e8..ecc0004 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:42Z
+ * Date: 2016-12-06T23:32:57Z
  */
 .oo-ui-window {
   background: transparent;
index f6e2a39..b47b0c8 100644 (file)
@@ -1,12 +1,12 @@
 /*!
- * OOjs UI v0.18.1
+ * OOjs UI v0.18.2
  * https://www.mediawiki.org/wiki/OOjs_UI
  *
  * Copyright 2011–2016 OOjs UI Team and other contributors.
  * Released under the MIT license
  * http://oojs.mit-license.org
  *
- * Date: 2016-11-29T22:57:37Z
+ * Date: 2016-12-06T23:32:53Z
  */
 ( function ( OO ) {
 
index 55a68db..441fe2d 100644 (file)
Binary files a/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin-invert.png and b/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin-invert.png differ
index 663913a..548e136 100644 (file)
@@ -1,4 +1,4 @@
 <?xml version="1.0" encoding="utf-8"?>
 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><style>* { fill: #fff }</style>
-    <path d="M19 12c0-3.9-3.1-7-7-7s-7 3.1-7 7c0 1.4.4 2.6 1.1 3.7L12 23l5.9-7.3c.7-1.1 1.1-2.3 1.1-3.7zm-7 4c-2.2 0-4-1.8-4-4s1.8-4 4-4 4 1.8 4 4-1.8 4-4 4z"/>
+    <path d="M19 12c0-3.9-3.1-7-7-7s-7 3.1-7 7c0 1.4.4 2.6 1.1 3.7L12 23l5.9-7.3c.7-1.1 1.1-2.3 1.1-3.7zm-7 3c-1.6 0-3-1.4-3-3s1.4-3 3-3 3 1.4 3 3-1.4 3-3 3z"/>
 </svg>
index c1676e6..2e7107d 100644 (file)
Binary files a/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin-progressive.png and b/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin-progressive.png differ
index a9631cc..daf032a 100644 (file)
@@ -1,4 +1,4 @@
 <?xml version="1.0" encoding="utf-8"?>
 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><style>* { fill: #36c }</style>
-    <path d="M19 12c0-3.9-3.1-7-7-7s-7 3.1-7 7c0 1.4.4 2.6 1.1 3.7L12 23l5.9-7.3c.7-1.1 1.1-2.3 1.1-3.7zm-7 4c-2.2 0-4-1.8-4-4s1.8-4 4-4 4 1.8 4 4-1.8 4-4 4z"/>
+    <path d="M19 12c0-3.9-3.1-7-7-7s-7 3.1-7 7c0 1.4.4 2.6 1.1 3.7L12 23l5.9-7.3c.7-1.1 1.1-2.3 1.1-3.7zm-7 3c-1.6 0-3-1.4-3-3s1.4-3 3-3 3 1.4 3 3-1.4 3-3 3z"/>
 </svg>
index 536e77c..ddb1c5c 100644 (file)
Binary files a/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin.png and b/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPin.png differ
index f1fa246..26fb6b7 100644 (file)
@@ -1,4 +1,4 @@
 <?xml version="1.0" encoding="utf-8"?>
 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
-    <path d="M19 12c0-3.9-3.1-7-7-7s-7 3.1-7 7c0 1.4.4 2.6 1.1 3.7L12 23l5.9-7.3c.7-1.1 1.1-2.3 1.1-3.7zm-7 4c-2.2 0-4-1.8-4-4s1.8-4 4-4 4 1.8 4 4-1.8 4-4 4z"/>
+    <path d="M19 12c0-3.9-3.1-7-7-7s-7 3.1-7 7c0 1.4.4 2.6 1.1 3.7L12 23l5.9-7.3c.7-1.1 1.1-2.3 1.1-3.7zm-7 3c-1.6 0-3-1.4-3-3s1.4-3 3-3 3 1.4 3 3-1.4 3-3 3z"/>
 </svg>
index 607354c..ee5de90 100644 (file)
Binary files a/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr-invert.png and b/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr-invert.png differ
index 43074af..cfa98d8 100644 (file)
@@ -1,5 +1,6 @@
 <?xml version="1.0" encoding="utf-8"?>
 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><style>* { fill: #fff }</style>
-    <path d="M24 4h-4V0h-2v4h-4v2h4v4h2V6h4z"/>
-    <path d="M18 11h-1V7.1l-.1-.1H13V5.1c-.3-.1-.7-.1-1-.1-3.9 0-7 3.1-7 7 0 1.4.4 2.6 1.1 3.7L12 23l5.9-7.3c.7-1.1 1.1-2.3 1.1-3.7 0-.3 0-.7-.1-1H18zm-6 5c-2.2 0-4-1.8-4-4s1.8-4 4-4 4 1.8 4 4-1.8 4-4 4z"/>
+  <path d="M24 4h-4V0h-2v4h-4v2h4v4h2V6h4V4z"/>
+  <path d="M18.9 11c.1.3.1.7.1 1 0 1.4-.4 2.6-1.1 3.7L12 23l-5.9-7.3C5.4 14.6 5 13.4 5 12c0-3.9 3.1-7 7-7 .3 0 .7 0 1 .1V7h3.9l.1.1V11h1.9zM15 12c0-1.6-1.4-3-3-3s-3 1.4-3 3 1.4 3 3 3 3-1.4 3-3z"/>
 </svg>
+
index 2fcf2e1..036a31d 100644 (file)
Binary files a/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr-progressive.png and b/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr-progressive.png differ
index 7dc09d4..7cf1509 100644 (file)
@@ -1,5 +1,6 @@
 <?xml version="1.0" encoding="utf-8"?>
 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><style>* { fill: #36c }</style>
-    <path d="M24 4h-4V0h-2v4h-4v2h4v4h2V6h4z"/>
-    <path d="M18 11h-1V7.1l-.1-.1H13V5.1c-.3-.1-.7-.1-1-.1-3.9 0-7 3.1-7 7 0 1.4.4 2.6 1.1 3.7L12 23l5.9-7.3c.7-1.1 1.1-2.3 1.1-3.7 0-.3 0-.7-.1-1H18zm-6 5c-2.2 0-4-1.8-4-4s1.8-4 4-4 4 1.8 4 4-1.8 4-4 4z"/>
+  <path d="M24 4h-4V0h-2v4h-4v2h4v4h2V6h4V4z"/>
+  <path d="M18.9 11c.1.3.1.7.1 1 0 1.4-.4 2.6-1.1 3.7L12 23l-5.9-7.3C5.4 14.6 5 13.4 5 12c0-3.9 3.1-7 7-7 .3 0 .7 0 1 .1V7h3.9l.1.1V11h1.9zM15 12c0-1.6-1.4-3-3-3s-3 1.4-3 3 1.4 3 3 3 3-1.4 3-3z"/>
 </svg>
+
index 88160bc..d8c1691 100644 (file)
Binary files a/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr.png and b/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-ltr.png differ
index d84970f..9d71335 100644 (file)
@@ -1,5 +1,6 @@
 <?xml version="1.0" encoding="utf-8"?>
 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
-    <path d="M24 4h-4V0h-2v4h-4v2h4v4h2V6h4z"/>
-    <path d="M18 11h-1V7.1l-.1-.1H13V5.1c-.3-.1-.7-.1-1-.1-3.9 0-7 3.1-7 7 0 1.4.4 2.6 1.1 3.7L12 23l5.9-7.3c.7-1.1 1.1-2.3 1.1-3.7 0-.3 0-.7-.1-1H18zm-6 5c-2.2 0-4-1.8-4-4s1.8-4 4-4 4 1.8 4 4-1.8 4-4 4z"/>
+  <path d="M24 4h-4V0h-2v4h-4v2h4v4h2V6h4V4z"/>
+  <path d="M18.9 11c.1.3.1.7.1 1 0 1.4-.4 2.6-1.1 3.7L12 23l-5.9-7.3C5.4 14.6 5 13.4 5 12c0-3.9 3.1-7 7-7 .3 0 .7 0 1 .1V7h3.9l.1.1V11h1.9zM15 12c0-1.6-1.4-3-3-3s-3 1.4-3 3 1.4 3 3 3 3-1.4 3-3z"/>
 </svg>
+
index 6ea8226..934d5cc 100644 (file)
Binary files a/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl-invert.png and b/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl-invert.png differ
index 6a4af93..8b02ddb 100644 (file)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><style>* { fill: #fff }</style>
-    <path d="M0 4h4V0h2v4h4v2H6v4H4V6H0z"/>
-    <path d="M6 11h1V7.1l.1-.1H11V5.1c.3-.1.7-.1 1-.1 3.9 0 7 3.1 7 7 0 1.4-.4 2.6-1.1 3.7L12 23l-5.9-7.3C5.4 14.6 5 13.4 5 12c0-.3 0-.7.1-1H6zm6 5c2.2 0 4-1.8 4-4s-1.8-4-4-4-4 1.8-4 4 1.8 4 4 4z"/>
+    <path d="M0 4h4V0h2v4h4v2H6v4H4V6H0"/>
+    <path d="M6 11h1V7.1l.1-.1H11V5.1c.3-.1.7-.1 1-.1 3.9 0 7 3.1 7 7 0 1.4-.4 2.6-1.1 3.7L12 23l-5.9-7.3C5.4 14.6 5 13.4 5 12c0-.3 0-.7.1-1H6zm6 4c1.65 0 3-1.35 3-3s-1.35-3-3-3-3 1.35-3 3 1.35 3 3 3z"/>
 </svg>
index 56b7924..be7c51e 100644 (file)
Binary files a/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl-progressive.png and b/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl-progressive.png differ
index 8108685..c920c8d 100644 (file)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><style>* { fill: #36c }</style>
-    <path d="M0 4h4V0h2v4h4v2H6v4H4V6H0z"/>
-    <path d="M6 11h1V7.1l.1-.1H11V5.1c.3-.1.7-.1 1-.1 3.9 0 7 3.1 7 7 0 1.4-.4 2.6-1.1 3.7L12 23l-5.9-7.3C5.4 14.6 5 13.4 5 12c0-.3 0-.7.1-1H6zm6 5c2.2 0 4-1.8 4-4s-1.8-4-4-4-4 1.8-4 4 1.8 4 4 4z"/>
+    <path d="M0 4h4V0h2v4h4v2H6v4H4V6H0"/>
+    <path d="M6 11h1V7.1l.1-.1H11V5.1c.3-.1.7-.1 1-.1 3.9 0 7 3.1 7 7 0 1.4-.4 2.6-1.1 3.7L12 23l-5.9-7.3C5.4 14.6 5 13.4 5 12c0-.3 0-.7.1-1H6zm6 4c1.65 0 3-1.35 3-3s-1.35-3-3-3-3 1.35-3 3 1.35 3 3 3z"/>
 </svg>
index 20aba25..7cc1f74 100644 (file)
Binary files a/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl.png and b/resources/lib/oojs-ui/themes/mediawiki/images/icons/mapPinAdd-rtl.png differ
index 8f35458..03c484a 100644 (file)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
-    <path d="M0 4h4V0h2v4h4v2H6v4H4V6H0z"/>
-    <path d="M6 11h1V7.1l.1-.1H11V5.1c.3-.1.7-.1 1-.1 3.9 0 7 3.1 7 7 0 1.4-.4 2.6-1.1 3.7L12 23l-5.9-7.3C5.4 14.6 5 13.4 5 12c0-.3 0-.7.1-1H6zm6 5c2.2 0 4-1.8 4-4s-1.8-4-4-4-4 1.8-4 4 1.8 4 4 4z"/>
+    <path d="M0 4h4V0h2v4h4v2H6v4H4V6H0"/>
+    <path d="M6 11h1V7.1l.1-.1H11V5.1c.3-.1.7-.1 1-.1 3.9 0 7 3.1 7 7 0 1.4-.4 2.6-1.1 3.7L12 23l-5.9-7.3C5.4 14.6 5 13.4 5 12c0-.3 0-.7.1-1H6zm6 4c1.65 0 3-1.35 3-3s-1.35-3-3-3-3 1.35-3 3 1.35 3 3 3z"/>
 </svg>
index cb46b11..d94b158 100644 (file)
@@ -30,6 +30,7 @@
                        $spinner = $.createSpinner( { size: 'small', type: 'inline' } );
                        $link.hide().after( $spinner );
 
+                       // @todo: data.messageHtml is no more. Convert to using errorformat=html.
                        api = new mw.Api();
                        api.rollback( page, user )
                                .then( function ( data ) {
diff --git a/tests/phan/bin/phan b/tests/phan/bin/phan
new file mode 100755 (executable)
index 0000000..07caee6
--- /dev/null
@@ -0,0 +1,45 @@
+#!/bin/sh
+
+# Note that this isn't loaded in via composer because then composer can
+# only be run with php7.0
+if [ ! -f "$PHAN" ]; then
+       echo "The environment variable PHAN must point to the 'phan' file"
+       echo "in a checkout of https://github.com/etsy/phan.git"
+       exit 1
+fi
+
+cd "$(dirname "$0")"
+
+# Root directory of project
+export ROOT="$(git rev-parse --show-toplevel)"
+
+# Phan's issues directory
+export ISSUES="${ROOT}/tests/phan/issues"
+
+# Go to the root of this git repo
+cd "$ROOT"
+
+# Get the current hash of HEAD
+export REV="$(git rev-parse HEAD)"
+
+# Destination for issues found
+export RUN="${ISSUES}/issues-${REV}"
+
+# Run the analysis, emitting output to the
+# issues file.
+php7.0 $PHAN \
+       --project-root-directory "$ROOT" \
+       --config-file "$ROOT/tests/phan/config.php" \
+       --output "$ROOT/tests/phan/issues/issues-${REV}" \
+       -j 4
+
+# Re-link the latest directory
+rm -f "${ISSUES}/latest"
+ln -s "${RUN}" "${ISSUES}/latest"
+
+# Output any issues that were found
+cat "${RUN}"
+
+if [ $(wc -l < ${RUN}) -ne 0 ]; then
+       exit 1
+fi
diff --git a/tests/phan/config.php b/tests/phan/config.php
new file mode 100644 (file)
index 0000000..7d4cfb9
--- /dev/null
@@ -0,0 +1,416 @@
+<?php
+
+use \Phan\Config;
+
+// If xdebug is enabled, we need to increase the nesting level for phan
+ini_set( 'xdebug.max_nesting_level', 1000 );
+
+/**
+ * This configuration will be read and overlayed on top of the
+ * default configuration. Command line arguments will be applied
+ * after this file is read.
+ *
+ * @see src/Phan/Config.php
+ * See Config for all configurable options.
+ *
+ * A Note About Paths
+ * ==================
+ *
+ * Files referenced from this file should be defined as
+ *
+ * ```
+ *   Config::projectPath('relative_path/to/file')
+ * ```
+ *
+ * where the relative path is relative to the root of the
+ * project which is defined as either the working directory
+ * of the phan executable or a path passed in via the CLI
+ * '-d' flag.
+ */
+return [
+       /**
+        * A list of individual files to include in analysis
+        * with a path relative to the root directory of the
+        * project. directory_list won't find .inc files so
+        * we augment it here.
+        */
+       'file_list' => [
+               'maintenance/7zip.inc',
+               'maintenance/backupPrefetch.inc',
+               'maintenance/commandLine.inc',
+               'maintenance/sqlite.inc',
+               'maintenance/userOptions.inc',
+               'maintenance/backup.inc',
+               'maintenance/cleanupTable.inc',
+               'maintenance/importImages.inc',
+               'maintenance/userDupes.inc',
+               'maintenance/language/checkLanguage.inc',
+               'maintenance/language/languages.inc',
+       ],
+
+       /**
+        * A list of directories that should be parsed for class and
+        * method information. After excluding the directories
+        * defined in exclude_analysis_directory_list, the remaining
+        * files will be statically analyzed for errors.
+        *
+        * Thus, both first-party and third-party code being used by
+        * your application should be included in this list.
+        */
+       'directory_list' => [
+               'includes/',
+               'languages/',
+               'maintenance/',
+               'mw-config/',
+               'resources/',
+               'skins/',
+               'vendor/',
+               'tests/phan/stubs/',
+       ],
+
+       /**
+        * A file list that defines files that will be excluded
+        * from parsing and analysis and will not be read at all.
+        *
+        * This is useful for excluding hopelessly unanalyzable
+        * files that can't be removed for whatever reason.
+        */
+       'exclude_file_list' => function_exists( 'xcache_get' ) ? [] : [
+               // References xcache which probably isn't installed
+               'includes/libs/objectcache/XCacheBagOStuff.php'
+       ],
+
+       /**
+        * A list of directories holding code that we want
+        * to parse, but not analyze. Also works for individual
+        * files.
+        */
+       "exclude_analysis_directory_list" => [
+               'vendor/',
+               'tests/phan/stubs/',
+               // The referenced classes are not available in vendor, only when
+               // included from composer.
+               'includes/composer/',
+               // Directly references classes that only exist in Translate extension
+               'maintenance/language/',
+               // External class
+               'includes/libs/jsminplus.php',
+       ],
+
+       /**
+        * Backwards Compatibility Checking. This is slow
+        * and expensive, but you should consider running
+        * it before upgrading your version of PHP to a
+        * new version that has backward compatibility
+        * breaks.
+        */
+       'backward_compatibility_checks' => false,
+
+       /**
+        * A set of fully qualified class-names for which
+        * a call to parent::__construct() is required
+        */
+       'parent_constructor_required' => [
+       ],
+
+       /**
+        * Run a quick version of checks that takes less
+        * time at the cost of not running as thorough
+        * an analysis. You should consider setting this
+        * to true only when you wish you had more issues
+        * to fix in your code base.
+        *
+        * In quick-mode the scanner doesn't rescan a function
+        * or a method's code block every time a call is seen.
+        * This means that the problem here won't be detected:
+        *
+        * ```php
+        * <?php
+        * function test($arg):int {
+        *      return $arg;
+        * }
+        * test("abc");
+        * ```
+        *
+        * This would normally generate:
+        *
+        * ```sh
+        * test.php:3 TypeError return string but `test()` is declared to return int
+        * ```
+        *
+        * The initial scan of the function's code block has no
+        * type information for `$arg`. It isn't until we see
+        * the call and rescan test()'s code block that we can
+        * detect that it is actually returning the passed in
+        * `string` instead of an `int` as declared.
+        */
+       'quick_mode' => false,
+
+       /**
+        * By default, Phan will not analyze all node types
+        * in order to save time. If this config is set to true,
+        * Phan will dig deeper into the AST tree and do an
+        * analysis on all nodes, possibly finding more issues.
+        *
+        * See \Phan\Analysis::shouldVisit for the set of skipped
+        * nodes.
+        */
+       'should_visit_all_nodes' => true,
+
+       /**
+        * If enabled, check all methods that override a
+        * parent method to make sure its signature is
+        * compatible with the parent's. This check
+        * can add quite a bit of time to the analysis.
+        */
+       'analyze_signature_compatibility' => true,
+
+       // Only emit critical issues
+       "minimum_severity" => 10,
+
+       /**
+        * If true, missing properties will be created when
+        * they are first seen. If false, we'll report an
+        * error message if there is an attempt to write
+        * to a class property that wasn't explicitly
+        * defined.
+        */
+       'allow_missing_properties' => false,
+
+       /**
+        * Allow null to be cast as any type and for any
+        * type to be cast to null. Setting this to false
+        * will cut down on false positives.
+        */
+       'null_casts_as_any_type' => true,
+
+       /**
+        * If enabled, scalars (int, float, bool, string, null)
+        * are treated as if they can cast to each other.
+        *
+        * MediaWiki is pretty lax and uses many scalar
+        * types interchangably.
+        */
+       'scalar_implicit_cast' => true,
+
+       /**
+        * If true, seemingly undeclared variables in the global
+        * scope will be ignored. This is useful for projects
+        * with complicated cross-file globals that you have no
+        * hope of fixing.
+        */
+       'ignore_undeclared_variables_in_global_scope' => false,
+
+       /**
+        * Set to true in order to attempt to detect dead
+        * (unreferenced) code. Keep in mind that the
+        * results will only be a guess given that classes,
+        * properties, constants and methods can be referenced
+        * as variables (like `$class->$property` or
+        * `$class->$method()`) in ways that we're unable
+        * to make sense of.
+        */
+       'dead_code_detection' => false,
+
+       /**
+        * If true, the dead code detection rig will
+        * prefer false negatives (not report dead code) to
+        * false positives (report dead code that is not
+        * actually dead) which is to say that the graph of
+        * references will create too many edges rather than
+        * too few edges when guesses have to be made about
+        * what references what.
+        */
+       'dead_code_detection_prefer_false_negative' => true,
+
+       /**
+        * If disabled, Phan will not read docblock type
+        * annotation comments (such as for @return, @param,
+        * @var, @suppress, @deprecated) and only rely on
+        * types expressed in code.
+        */
+       'read_type_annotations' => true,
+
+       /**
+        * If a file path is given, the code base will be
+        * read from and written to the given location in
+        * order to attempt to save some work from being
+        * done. Only changed files will get analyzed if
+        * the file is read
+        */
+       'stored_state_file_path' => null,
+
+       /**
+        * Set to true in order to ignore issue suppression.
+        * This is useful for testing the state of your code, but
+        * unlikely to be useful outside of that.
+        */
+       'disable_suppression' => false,
+
+       /**
+        * If set to true, we'll dump the AST instead of
+        * analyzing files
+        */
+       'dump_ast' => false,
+
+       /**
+        * If set to a string, we'll dump the fully qualified lowercase
+        * function and method signatures instead of analyzing files.
+        */
+       'dump_signatures_file' => null,
+
+       /**
+        * If true (and if stored_state_file_path is set) we'll
+        * look at the list of files passed in and expand the list
+        * to include files that depend on the given files
+        */
+       'expand_file_list' => false,
+
+       // Include a progress bar in the output
+       'progress_bar' => false,
+
+       /**
+        * The probability of actually emitting any progress
+        * bar update. Setting this to something very low
+        * is good for reducing network IO and filling up
+        * your terminal's buffer when running phan on a
+        * remote host.
+        */
+       'progress_bar_sample_rate' => 0.005,
+
+       /**
+        * The number of processes to fork off during the analysis
+        * phase.
+        */
+       'processes' => 1,
+
+       /**
+        * Add any issue types (such as 'PhanUndeclaredMethod')
+        * to this black-list to inhibit them from being reported.
+        */
+       'suppress_issue_types' => [
+               // MediaWiki has so much deprecated class usage it's a bit hopeless to
+               // fix this immediately
+               'PhanDeprecatedClass',
+               'PhanDeprecatedFunction',
+               'PhanDeprecatedProperty',
+               // There are arround 1400 usages of undeclared properties.
+               // php is ok with that but it's a code smell.
+               'PhanUndeclaredProperty',
+       ],
+
+       /**
+        * If empty, no filter against issues types will be applied.
+        * If this white-list is non-empty, only issues within the list
+        * will be emitted by Phan.
+        */
+       'whitelist_issue_types' => [
+               // 'PhanAccessMethodPrivate',
+               // 'PhanAccessMethodProtected',
+               // 'PhanAccessNonStaticToStatic',
+               // 'PhanAccessPropertyPrivate',
+               // 'PhanAccessPropertyProtected',
+               // 'PhanAccessSignatureMismatch',
+               // 'PhanAccessSignatureMismatchInternal',
+               // 'PhanAccessStaticToNonStatic',
+               // 'PhanCompatibleExpressionPHP7',
+               // 'PhanCompatiblePHP7',
+               // 'PhanContextNotObject',
+               // 'PhanDeprecatedClass',
+               // 'PhanDeprecatedFunction',
+               // 'PhanDeprecatedProperty',
+               // 'PhanEmptyFile',
+               // 'PhanNonClassMethodCall',
+               // 'PhanNoopArray',
+               // 'PhanNoopClosure',
+               // 'PhanNoopConstant',
+               // 'PhanNoopProperty',
+               // 'PhanNoopVariable',
+               // 'PhanParamRedefined',
+               // 'PhanParamReqAfterOpt',
+               // 'PhanParamSignatureMismatch',
+               // 'PhanParamSignatureMismatchInternal',
+               // 'PhanParamSpecial1',
+               // 'PhanParamSpecial2',
+               // 'PhanParamSpecial3',
+               // 'PhanParamSpecial4',
+               // 'PhanParamTooFew',
+               // 'PhanParamTooFewInternal',
+               // 'PhanParamTooMany',
+               // 'PhanParamTooManyInternal',
+               // 'PhanParamTypeMismatch',
+               // 'PhanParentlessClass',
+               // 'PhanRedefineClass',
+               // 'PhanRedefineClassInternal',
+               // 'PhanRedefineFunction',
+               // 'PhanRedefineFunctionInternal',
+               // 'PhanStaticCallToNonStatic',
+               // 'PhanSyntaxError',
+               // 'PhanTraitParentReference',
+               // 'PhanTypeArrayOperator',
+               // 'PhanTypeArraySuspicious',
+               // 'PhanTypeComparisonFromArray',
+               // 'PhanTypeComparisonToArray',
+               // 'PhanTypeConversionFromArray',
+               // 'PhanTypeInstantiateAbstract',
+               // 'PhanTypeInstantiateInterface',
+               // 'PhanTypeInvalidLeftOperand',
+               // 'PhanTypeInvalidRightOperand',
+               // 'PhanTypeMismatchArgument',
+               // 'PhanTypeMismatchArgumentInternal',
+               // 'PhanTypeMismatchDefault',
+               // 'PhanTypeMismatchForeach',
+               // 'PhanTypeMismatchProperty',
+               // 'PhanTypeMismatchReturn',
+               // 'PhanTypeMissingReturn',
+               // 'PhanTypeNonVarPassByRef',
+               // 'PhanTypeParentConstructorCalled',
+               // 'PhanTypeVoidAssignment',
+               // 'PhanUnanalyzable',
+               // 'PhanUndeclaredClass',
+               // 'PhanUndeclaredClassCatch',
+               // 'PhanUndeclaredClassConstant',
+               // 'PhanUndeclaredClassInstanceof',
+               // 'PhanUndeclaredClassMethod',
+               // 'PhanUndeclaredClassReference',
+               // 'PhanUndeclaredConstant',
+               // 'PhanUndeclaredExtendedClass',
+               // 'PhanUndeclaredFunction',
+               // 'PhanUndeclaredInterface',
+               // 'PhanUndeclaredMethod',
+               // 'PhanUndeclaredProperty',
+               // 'PhanUndeclaredStaticMethod',
+               // 'PhanUndeclaredStaticProperty',
+               // 'PhanUndeclaredTrait',
+               // 'PhanUndeclaredTypeParameter',
+               // 'PhanUndeclaredTypeProperty',
+               // 'PhanUndeclaredVariable',
+               // 'PhanUnreferencedClass',
+               // 'PhanUnreferencedConstant',
+               // 'PhanUnreferencedMethod',
+               // 'PhanUnreferencedProperty',
+               // 'PhanVariableUseClause',
+       ],
+
+       /**
+        * Override to hardcode existence and types of (non-builtin) globals in the global scope.
+        * Class names must be prefixed with '\\'.
+        * (E.g. ['_FOO' => '\\FooClass', 'page' => '\\PageClass', 'userId' => 'int'])
+        */
+       'globals_type_map' => [
+               'IP' => 'string',
+       ],
+
+       // Emit issue messages with markdown formatting
+       'markdown_issue_messages' => false,
+
+       /**
+        * Enable or disable support for generic templated
+        * class types.
+        */
+       'generic_types_enabled' => true,
+
+       // A list of plugin files to execute
+       'plugins' => [
+       ],
+];
diff --git a/tests/phan/issues/.gitkeep b/tests/phan/issues/.gitkeep
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/tests/phan/stubs/README b/tests/phan/stubs/README
new file mode 100644 (file)
index 0000000..c458ab5
--- /dev/null
@@ -0,0 +1,3 @@
+These stubs describe how code that is not available at analysis time should be
+used. No implementations are necessary, just define the classes and their
+methods and use phpdoc to describe what arguments are allowed.
diff --git a/tests/phan/stubs/hhvm.php b/tests/phan/stubs/hhvm.php
new file mode 100644 (file)
index 0000000..8ffcdfb
--- /dev/null
@@ -0,0 +1,27 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+// @codingStandardsIgnoreFile
+
+/**
+ * @param callable $callback
+ * @param mixed ...$parameters
+ */
+function register_postsend_function( $callback ) {
+}
+
diff --git a/tests/phan/stubs/mail.php b/tests/phan/stubs/mail.php
new file mode 100644 (file)
index 0000000..e906cdb
--- /dev/null
@@ -0,0 +1,89 @@
+<?php
+
+// @codingStandardsIgnoreFile
+
+/**
+ * Minimal set of classes necessary for UserMailer to be happy. Types
+ * taken from documentation at pear.php.net.
+ */
+class PEAR {
+       /**
+        * @param mixed $data
+        * @return bool
+        */
+       public static function isError( $data ) {
+       }
+}
+
+class PEAR_Error {
+       /**
+        * @return string
+        */
+       public function getMessage() {
+       }
+}
+
+class Mail {
+       /**
+        * @param string $driver
+        * @param array $params
+        * @return self
+        */
+       static public function factory( $driver, array $params = [] ) {
+       }
+
+       /**
+        * @param mixed $recipients
+        * @param array $headers
+        * @param string $body
+        * @return bool|PEAR_Error
+        */
+       public function send( $recipients, array $headers, $body ) {
+       }
+}
+
+class Mail_smtp extends Mail {
+}
+
+class Mail_mime {
+       /**
+        * @param mixed $params
+        */
+       public function __construct( $params = [] ) {
+       }
+
+       /**
+        * @param string $data
+        * @param bool $isfile
+        * @param bool $append
+        * @return bool|PEAR_Error
+        */
+       public function setTXTBody( $data, $isfile = false, $append = false ) {
+       }
+
+       /**
+        * @param string $data
+        * @param bool $isfile
+        * @return bool|PEAR_Error
+        */
+       public function setHTMLBody( $data, $isfile = false ) {
+       }
+
+       /**
+        * @param array|null $parms
+        * @param mixed $filename
+        * @param bool $skip_head
+        * @return string|bool|PEAR_Error
+        */
+       public function get( $params = null, $filename = null, $skip_head = false ) {
+       }
+
+       /**
+        * @param array|null $xtra_headers
+        * @param bool $overwrite
+        * @param bool $skip_content
+        * @return array
+        */
+       public function headers( array $xtra_headers = null, $overwrite = false, $skip_content = false ) {
+       }
+}
diff --git a/tests/phan/stubs/wikidiff.php b/tests/phan/stubs/wikidiff.php
new file mode 100644 (file)
index 0000000..9bd5d8d
--- /dev/null
@@ -0,0 +1,28 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+// @codingStandardsIgnoreFile
+
+/**
+ * @param string $text1
+ * @param string $text2
+ * @param int $numContextLines
+ * @return string
+ */
+function wikidiff2_do_diff( $text1, $text2, $numContextLines ) {
+}
index baa481e..45cfdbf 100644 (file)
@@ -11,14 +11,23 @@ abstract class ResourceLoaderTestCase extends MediaWikiTestCase {
        const BLANK_VERSION = '09p30q0';
 
        /**
-        * @param string $lang
-        * @param string $dir
+        * @param array|string $options Language code or options array
+        * - string 'lang' Language code
+        * - string 'dir' Language direction (ltr or rtl)
         * @return ResourceLoaderContext
         */
-       protected function getResourceLoaderContext( $lang = 'en', $dir = 'ltr' ) {
+       protected function getResourceLoaderContext( $options = [] ) {
+               if ( is_string( $options ) ) {
+                       // Back-compat for extension tests
+                       $options = [ 'lang' => $options ];
+               }
+               $options += [
+                       'lang' => 'en',
+                       'dir' => 'ltr',
+               ];
                $resourceLoader = new ResourceLoader();
                $request = new FauxRequest( [
-                               'lang' => $lang,
+                               'lang' => $options['lang'],
                                'modules' => 'startup',
                                'only' => 'scripts',
                                'skin' => 'vector',
@@ -28,7 +37,7 @@ abstract class ResourceLoaderTestCase extends MediaWikiTestCase {
                        ->setConstructorArgs( [ $resourceLoader, $request ] )
                        ->setMethods( [ 'getDirection' ] )
                        ->getMock();
-               $ctx->method( 'getDirection' )->willReturn( $dir );
+               $ctx->method( 'getDirection' )->willReturn( $options['dir'] );
                return $ctx;
        }
 
index 93687df..bdec0a5 100644 (file)
@@ -1233,7 +1233,7 @@ class WatchedItemQueryServiceUnitTest extends PHPUnit_Framework_TestCase {
                        ->with( 'watchlisttoken' )
                        ->willReturn( '0123456789abcdef' );
 
-               $this->setExpectedException( UsageException::class, 'Incorrect watchlist token provided' );
+               $this->setExpectedException( ApiUsageException::class, 'Incorrect watchlist token provided' );
                $queryService->getWatchedItemsWithRecentChangeInfo(
                        $user,
                        [ 'watchlistOwner' => $otherUser, 'watchlistOwnerToken' => $token ]
index 8b75d56..96f3e44 100644 (file)
@@ -20,7 +20,7 @@ class ApiBaseTest extends ApiTestCase {
        }
 
        /**
-        * @expectedException UsageException
+        * @expectedException ApiUsageException
         * @covers ApiBase::requireOnlyOneParameter
         */
        public function testRequireOnlyOneParameterZero() {
@@ -32,7 +32,7 @@ class ApiBaseTest extends ApiTestCase {
        }
 
        /**
-        * @expectedException UsageException
+        * @expectedException ApiUsageException
         * @covers ApiBase::requireOnlyOneParameter
         */
        public function testRequireOnlyOneParameterTrue() {
@@ -58,10 +58,10 @@ class ApiBaseTest extends ApiTestCase {
                $context->setRequest( new FauxRequest( $input !== null ? [ 'foo' => $input ] : [] ) );
                $wrapper->mMainModule = new ApiMain( $context );
 
-               if ( $expected instanceof UsageException ) {
+               if ( $expected instanceof ApiUsageException ) {
                        try {
                                $wrapper->getParameterFromSettings( 'foo', $paramSettings, true );
-                       } catch ( UsageException $ex ) {
+                       } catch ( ApiUsageException $ex ) {
                                $this->assertEquals( $expected, $ex );
                        }
                } else {
@@ -73,9 +73,7 @@ class ApiBaseTest extends ApiTestCase {
 
        public static function provideGetParameterFromSettings() {
                $warnings = [
-                       'The value passed for \'foo\' contains invalid or non-normalized data. Textual data should ' .
-                       'be valid, NFC-normalized Unicode without C0 control characters other than ' .
-                       'HT (\\t), LF (\\n), and CR (\\r).'
+                       [ 'apiwarn-badutf8', 'foo' ],
                ];
 
                $c0 = '';
@@ -96,7 +94,7 @@ class ApiBaseTest extends ApiTestCase {
                        'String param, required, empty' => [
                                '',
                                [ ApiBase::PARAM_DFLT => 'default', ApiBase::PARAM_REQUIRED => true ],
-                               new UsageException( 'The foo parameter must be set', 'nofoo' ),
+                               ApiUsageException::newWithMessage( null, [ 'apierror-missingparam', 'foo' ] ),
                                []
                        ],
                        'Multi-valued parameter' => [
@@ -126,4 +124,48 @@ class ApiBaseTest extends ApiTestCase {
                ];
        }
 
+       public function testErrorArrayToStatus() {
+               $mock = new MockApi();
+
+               // Sanity check empty array
+               $expect = Status::newGood();
+               $this->assertEquals( $expect, $mock->errorArrayToStatus( [] ) );
+
+               // No blocked $user, so no special block handling
+               $expect = Status::newGood();
+               $expect->fatal( 'blockedtext' );
+               $expect->fatal( 'autoblockedtext' );
+               $expect->fatal( 'mainpage' );
+               $expect->fatal( 'parentheses', 'foobar' );
+               $this->assertEquals( $expect, $mock->errorArrayToStatus( [
+                       [ 'blockedtext' ],
+                       [ 'autoblockedtext' ],
+                       'mainpage',
+                       [ 'parentheses', 'foobar' ],
+               ] ) );
+
+               // Has a blocked $user, so special block handling
+               $user = $this->getMutableTestUser()->getUser();
+               $block = new \Block( [
+                       'address' => $user->getName(),
+                       'user' => $user->getID(),
+                       'reason' => __METHOD__,
+                       'expiry' => time() + 100500,
+               ] );
+               $block->insert();
+               $blockinfo = [ 'blockinfo' => ApiQueryUserInfo::getBlockInfo( $block ) ];
+
+               $expect = Status::newGood();
+               $expect->fatal( ApiMessage::create( 'apierror-blocked', 'blocked', $blockinfo ) );
+               $expect->fatal( ApiMessage::create( 'apierror-autoblocked', 'autoblocked', $blockinfo ) );
+               $expect->fatal( 'mainpage' );
+               $expect->fatal( 'parentheses', 'foobar' );
+               $this->assertEquals( $expect, $mock->errorArrayToStatus( [
+                       [ 'blockedtext' ],
+                       [ 'autoblockedtext' ],
+                       'mainpage',
+                       [ 'parentheses', 'foobar' ],
+               ], $user ) );
+       }
+
 }
index d2dccf9..08fc128 100644 (file)
@@ -65,8 +65,8 @@ class ApiBlockTest extends ApiTestCase {
        }
 
        /**
-        * @expectedException UsageException
-        * @expectedExceptionMessage The token parameter must be set
+        * @expectedException ApiUsageException
+        * @expectedExceptionMessage The "token" parameter must be set
         */
        public function testBlockingActionWithNoToken() {
                $this->doApiRequest(
index 3ad16d1..bb4ea75 100644 (file)
@@ -160,10 +160,8 @@ class ApiContinuationManagerTest extends MediaWikiTestCase {
                try {
                        self::getManager( 'foo', $allModules, [ 'mock1', 'mock2' ] );
                        $this->fail( 'Expected exception not thrown' );
-               } catch ( UsageException $ex ) {
-                       $this->assertSame(
-                               'Invalid continue param. You should pass the original value returned by the previous query',
-                               $ex->getMessage(),
+               } catch ( ApiUsageException $ex ) {
+                       $this->assertTrue( ApiTestCase::apiExceptionHasCode( $ex, 'badcontinue' ),
                                'Expected exception'
                        );
                }
index 02d0a0d..0ffcbca 100644 (file)
@@ -195,9 +195,9 @@ class ApiEditPageTest extends ApiTestCase {
                                'section' => '9999',
                                'text' => 'text',
                        ] );
-                       $this->fail( "Should have raised a UsageException" );
-               } catch ( UsageException $e ) {
-                       $this->assertEquals( 'nosuchsection', $e->getCodeString() );
+                       $this->fail( "Should have raised an ApiUsageException" );
+               } catch ( ApiUsageException $e ) {
+                       $this->assertTrue( self::apiExceptionHasCode( $e, 'nosuchsection' ) );
                }
        }
 
@@ -333,8 +333,8 @@ class ApiEditPageTest extends ApiTestCase {
                        ], null, self::$users['sysop']->getUser() );
 
                        $this->fail( 'redirect-appendonly error expected' );
-               } catch ( UsageException $ex ) {
-                       $this->assertEquals( 'redirect-appendonly', $ex->getCodeString() );
+               } catch ( ApiUsageException $ex ) {
+                       $this->assertTrue( self::apiExceptionHasCode( $ex, 'redirect-appendonly' ) );
                }
        }
 
@@ -369,8 +369,8 @@ class ApiEditPageTest extends ApiTestCase {
                        ], null, self::$users['sysop']->getUser() );
 
                        $this->fail( 'edit conflict expected' );
-               } catch ( UsageException $ex ) {
-                       $this->assertEquals( 'editconflict', $ex->getCodeString() );
+               } catch ( ApiUsageException $ex ) {
+                       $this->assertTrue( self::apiExceptionHasCode( $ex, 'editconflict' ) );
                }
        }
 
@@ -474,7 +474,7 @@ class ApiEditPageTest extends ApiTestCase {
 
        public function testCheckDirectApiEditingDisallowed_forNonTextContent() {
                $this->setExpectedException(
-                       'UsageException',
+                       'ApiUsageException',
                        'Direct editing via API is not supported for content model ' .
                                'testing used by Dummy:ApiEditPageTest_nonTextPageEdit'
                );
index d13b00b..1b7f6bf 100644 (file)
@@ -5,6 +5,30 @@
  */
 class ApiErrorFormatterTest extends MediaWikiLangTestCase {
 
+       /**
+        * @covers ApiErrorFormatter
+        */
+       public function testErrorFormatterBasics() {
+               $result = new ApiResult( 8388608 );
+               $formatter = new ApiErrorFormatter( $result, Language::factory( 'de' ), 'wikitext', false );
+               $this->assertSame( 'de', $formatter->getLanguage()->getCode() );
+
+               $formatter->addMessagesFromStatus( null, Status::newGood() );
+               $this->assertSame(
+                       [ ApiResult::META_TYPE => 'assoc' ],
+                       $result->getResultData()
+               );
+
+               $this->assertSame( [], $formatter->arrayFromStatus( Status::newGood() ) );
+
+               $wrappedFormatter = TestingAccessWrapper::newFromObject( $formatter );
+               $this->assertSame(
+                       'Blah "kbd" <X> 😊',
+                       $wrappedFormatter->stripMarkup( 'Blah <kbd>kbd</kbd> <b>&lt;X&gt;</b> &#x1f60a;' ),
+                       'stripMarkup'
+               );
+       }
+
        /**
         * @covers ApiErrorFormatter
         * @dataProvider provideErrorFormatter
@@ -22,7 +46,7 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase {
 
                $formatter->addWarning( 'string', 'mainpage' );
                $formatter->addError( 'err', 'mainpage' );
-               $this->assertSame( $expect1, $result->getResultData(), 'Simple test' );
+               $this->assertEquals( $expect1, $result->getResultData(), 'Simple test' );
 
                $result->reset();
                $formatter->addWarning( 'foo', 'mainpage' );
@@ -35,6 +59,17 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase {
                $formatter->addError( 'errWithData', $msg2 );
                $this->assertSame( $expect2, $result->getResultData(), 'Complex test' );
 
+               $this->assertEquals(
+                       $this->removeModuleTag( $expect2['warnings'][2] ),
+                       $formatter->formatMessage( $msg1 ),
+                       'formatMessage test 1'
+               );
+               $this->assertEquals(
+                       $this->removeModuleTag( $expect2['warnings'][3] ),
+                       $formatter->formatMessage( $msg2 ),
+                       'formatMessage test 2'
+               );
+
                $result->reset();
                $status = Status::newGood();
                $status->warning( 'mainpage' );
@@ -47,245 +82,256 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase {
                $this->assertSame( $expect3, $result->getResultData(), 'Status test' );
 
                $this->assertSame(
-                       $expect3['errors']['status'],
+                       array_map( [ $this, 'removeModuleTag' ], $expect3['errors'] ),
                        $formatter->arrayFromStatus( $status, 'error' ),
                        'arrayFromStatus test for error'
                );
                $this->assertSame(
-                       $expect3['warnings']['status'],
+                       array_map( [ $this, 'removeModuleTag' ], $expect3['warnings'] ),
                        $formatter->arrayFromStatus( $status, 'warning' ),
                        'arrayFromStatus test for warning'
                );
        }
 
+       private function removeModuleTag( $s ) {
+               if ( is_array( $s ) ) {
+                       unset( $s['module'] );
+               }
+               return $s;
+       }
+
        public static function provideErrorFormatter() {
-               $mainpagePlain = wfMessage( 'mainpage' )->useDatabase( false )->plain();
-               $parensPlain = wfMessage( 'parentheses', 'foobar' )->useDatabase( false )->plain();
-               $mainpageText = wfMessage( 'mainpage' )->inLanguage( 'de' )->text();
-               $parensText = wfMessage( 'parentheses', 'foobar' )->inLanguage( 'de' )->text();
+               $mainpageText = wfMessage( 'mainpage' )->inLanguage( 'de' )->useDatabase( false )->text();
+               $parensText = wfMessage( 'parentheses', 'foobar' )->inLanguage( 'de' )
+                       ->useDatabase( false )->text();
+               $mainpageHTML = wfMessage( 'mainpage' )->inLanguage( 'en' )->parse();
+               $parensHTML = wfMessage( 'parentheses', 'foobar' )->inLanguage( 'en' )->parse();
                $C = ApiResult::META_CONTENT;
                $I = ApiResult::META_INDEXED_TAG_NAME;
+               $overriddenData = [ 'overriddenData' => true, ApiResult::META_TYPE => 'assoc' ];
 
                return [
-                       [ 'wikitext', 'de', true,
+                       $tmp = [ 'wikitext', 'de', false,
                                [
                                        'errors' => [
-                                               'err' => [
-                                                       [ 'code' => 'mainpage', 'text' => $mainpageText, $C => 'text' ],
-                                                       $I => 'error',
-                                               ],
+                                               [ 'code' => 'mainpage', 'text' => $mainpageText, 'module' => 'err', $C => 'text' ],
+                                               $I => 'error',
                                        ],
                                        'warnings' => [
-                                               'string' => [
-                                                       [ 'code' => 'mainpage', 'text' => $mainpageText, $C => 'text' ],
-                                                       $I => 'warning',
-                                               ],
+                                               [ 'code' => 'mainpage', 'text' => $mainpageText, 'module' => 'string', $C => 'text' ],
+                                               $I => 'warning',
                                        ],
                                ],
                                [
                                        'errors' => [
-                                               'errWithData' => [
-                                                       [ 'code' => 'overriddenCode', 'text' => $mainpageText,
-                                                               'overriddenData' => true, $C => 'text' ],
-                                                       $I => 'error',
-                                               ],
+                                               [ 'code' => 'overriddenCode', 'text' => $mainpageText,
+                                                       'data' => $overriddenData, 'module' => 'errWithData', $C => 'text' ],
+                                               $I => 'error',
                                        ],
                                        'warnings' => [
-                                               'messageWithData' => [
-                                                       [ 'code' => 'overriddenCode', 'text' => $mainpageText,
-                                                               'overriddenData' => true, $C => 'text' ],
-                                                       $I => 'warning',
-                                               ],
-                                               'message' => [
-                                                       [ 'code' => 'mainpage', 'text' => $mainpageText, $C => 'text' ],
-                                                       $I => 'warning',
-                                               ],
-                                               'foo' => [
-                                                       [ 'code' => 'mainpage', 'text' => $mainpageText, $C => 'text' ],
-                                                       [ 'code' => 'parentheses', 'text' => $parensText, $C => 'text' ],
-                                                       $I => 'warning',
-                                               ],
+                                               [ 'code' => 'mainpage', 'text' => $mainpageText, 'module' => 'foo', $C => 'text' ],
+                                               [ 'code' => 'parentheses', 'text' => $parensText, 'module' => 'foo', $C => 'text' ],
+                                               [ 'code' => 'mainpage', 'text' => $mainpageText, 'module' => 'message', $C => 'text' ],
+                                               [ 'code' => 'overriddenCode', 'text' => $mainpageText,
+                                                       'data' => $overriddenData, 'module' => 'messageWithData', $C => 'text' ],
+                                               $I => 'warning',
                                        ],
                                ],
                                [
                                        'errors' => [
-                                               'status' => [
-                                                       [ 'code' => 'mainpage', 'text' => $mainpageText, $C => 'text' ],
-                                                       [ 'code' => 'parentheses', 'text' => $parensText, $C => 'text' ],
-                                                       $I => 'error',
-                                               ],
+                                               [ 'code' => 'mainpage', 'text' => $mainpageText, 'module' => 'status', $C => 'text' ],
+                                               [ 'code' => 'parentheses', 'text' => $parensText, 'module' => 'status', $C => 'text' ],
+                                               $I => 'error',
                                        ],
                                        'warnings' => [
-                                               'status' => [
-                                                       [ 'code' => 'mainpage', 'text' => $mainpageText, $C => 'text' ],
-                                                       [ 'code' => 'parentheses', 'text' => $parensText, $C => 'text' ],
-                                                       [ 'code' => 'overriddenCode', 'text' => $mainpageText,
-                                                               'overriddenData' => true, $C => 'text' ],
-                                                       $I => 'warning',
-                                               ],
+                                               [ 'code' => 'mainpage', 'text' => $mainpageText, 'module' => 'status', $C => 'text' ],
+                                               [ 'code' => 'parentheses', 'text' => $parensText, 'module' => 'status', $C => 'text' ],
+                                               [ 'code' => 'overriddenCode', 'text' => $mainpageText,
+                                                       'data' => $overriddenData, 'module' => 'status', $C => 'text' ],
+                                               $I => 'warning',
+                                       ],
+                               ],
+                       ],
+                       [ 'plaintext' ] + $tmp, // For these messages, plaintext and wikitext are the same
+                       [ 'html', 'en', true,
+                               [
+                                       'errors' => [
+                                               [ 'code' => 'mainpage', 'html' => $mainpageHTML, 'module' => 'err', $C => 'html' ],
+                                               $I => 'error',
+                                       ],
+                                       'warnings' => [
+                                               [ 'code' => 'mainpage', 'html' => $mainpageHTML, 'module' => 'string', $C => 'html' ],
+                                               $I => 'warning',
+                                       ],
+                               ],
+                               [
+                                       'errors' => [
+                                               [ 'code' => 'overriddenCode', 'html' => $mainpageHTML,
+                                                       'data' => $overriddenData, 'module' => 'errWithData', $C => 'html' ],
+                                               $I => 'error',
+                                       ],
+                                       'warnings' => [
+                                               [ 'code' => 'mainpage', 'html' => $mainpageHTML, 'module' => 'foo', $C => 'html' ],
+                                               [ 'code' => 'parentheses', 'html' => $parensHTML, 'module' => 'foo', $C => 'html' ],
+                                               [ 'code' => 'mainpage', 'html' => $mainpageHTML, 'module' => 'message', $C => 'html' ],
+                                               [ 'code' => 'overriddenCode', 'html' => $mainpageHTML,
+                                                       'data' => $overriddenData, 'module' => 'messageWithData', $C => 'html' ],
+                                               $I => 'warning',
+                                       ],
+                               ],
+                               [
+                                       'errors' => [
+                                               [ 'code' => 'mainpage', 'html' => $mainpageHTML, 'module' => 'status', $C => 'html' ],
+                                               [ 'code' => 'parentheses', 'html' => $parensHTML, 'module' => 'status', $C => 'html' ],
+                                               $I => 'error',
+                                       ],
+                                       'warnings' => [
+                                               [ 'code' => 'mainpage', 'html' => $mainpageHTML, 'module' => 'status', $C => 'html' ],
+                                               [ 'code' => 'parentheses', 'html' => $parensHTML, 'module' => 'status', $C => 'html' ],
+                                               [ 'code' => 'overriddenCode', 'html' => $mainpageHTML,
+                                                       'data' => $overriddenData, 'module' => 'status', $C => 'html' ],
+                                               $I => 'warning',
                                        ],
                                ],
                        ],
                        [ 'raw', 'fr', true,
                                [
                                        'errors' => [
-                                               'err' => [
-                                                       [
-                                                               'code' => 'mainpage',
-                                                               'key' => 'mainpage',
-                                                               'params' => [ $I => 'param' ]
-                                                       ],
-                                                       $I => 'error',
+                                               [
+                                                       'code' => 'mainpage',
+                                                       'key' => 'mainpage',
+                                                       'params' => [ $I => 'param' ],
+                                                       'module' => 'err',
                                                ],
+                                               $I => 'error',
                                        ],
                                        'warnings' => [
-                                               'string' => [
-                                                       [
-                                                               'code' => 'mainpage',
-                                                               'key' => 'mainpage',
-                                                               'params' => [ $I => 'param' ]
-                                                       ],
-                                                       $I => 'warning',
+                                               [
+                                                       'code' => 'mainpage',
+                                                       'key' => 'mainpage',
+                                                       'params' => [ $I => 'param' ],
+                                                       'module' => 'string',
                                                ],
+                                               $I => 'warning',
                                        ],
                                ],
                                [
                                        'errors' => [
-                                               'errWithData' => [
-                                                       [
-                                                               'code' => 'overriddenCode',
-                                                               'key' => 'mainpage',
-                                                               'params' => [ $I => 'param' ],
-                                                               'overriddenData' => true
-                                                       ],
-                                                       $I => 'error',
+                                               [
+                                                       'code' => 'overriddenCode',
+                                                       'key' => 'mainpage',
+                                                       'params' => [ $I => 'param' ],
+                                                       'data' => $overriddenData,
+                                                       'module' => 'errWithData',
                                                ],
+                                               $I => 'error',
                                        ],
                                        'warnings' => [
-                                               'messageWithData' => [
-                                                       [
-                                                               'code' => 'overriddenCode',
-                                                               'key' => 'mainpage',
-                                                               'params' => [ $I => 'param' ],
-                                                               'overriddenData' => true
-                                                       ],
-                                                       $I => 'warning',
+                                               [
+                                                       'code' => 'mainpage',
+                                                       'key' => 'mainpage',
+                                                       'params' => [ $I => 'param' ],
+                                                       'module' => 'foo',
+                                               ],
+                                               [
+                                                       'code' => 'parentheses',
+                                                       'key' => 'parentheses',
+                                                       'params' => [ 'foobar', $I => 'param' ],
+                                                       'module' => 'foo',
                                                ],
-                                               'message' => [
-                                                       [
-                                                               'code' => 'mainpage',
-                                                               'key' => 'mainpage',
-                                                               'params' => [ $I => 'param' ]
-                                                       ],
-                                                       $I => 'warning',
+                                               [
+                                                       'code' => 'mainpage',
+                                                       'key' => 'mainpage',
+                                                       'params' => [ $I => 'param' ],
+                                                       'module' => 'message',
                                                ],
-                                               'foo' => [
-                                                       [
-                                                               'code' => 'mainpage',
-                                                               'key' => 'mainpage',
-                                                               'params' => [ $I => 'param' ]
-                                                       ],
-                                                       [
-                                                               'code' => 'parentheses',
-                                                               'key' => 'parentheses',
-                                                               'params' => [ 'foobar', $I => 'param' ]
-                                                       ],
-                                                       $I => 'warning',
+                                               [
+                                                       'code' => 'overriddenCode',
+                                                       'key' => 'mainpage',
+                                                       'params' => [ $I => 'param' ],
+                                                       'data' => $overriddenData,
+                                                       'module' => 'messageWithData',
                                                ],
+                                               $I => 'warning',
                                        ],
                                ],
                                [
                                        'errors' => [
-                                               'status' => [
-                                                       [
-                                                               'code' => 'mainpage',
-                                                               'key' => 'mainpage',
-                                                               'params' => [ $I => 'param' ]
-                                                       ],
-                                                       [
-                                                               'code' => 'parentheses',
-                                                               'key' => 'parentheses',
-                                                               'params' => [ 'foobar', $I => 'param' ]
-                                                       ],
-                                                       $I => 'error',
+                                               [
+                                                       'code' => 'mainpage',
+                                                       'key' => 'mainpage',
+                                                       'params' => [ $I => 'param' ],
+                                                       'module' => 'status',
+                                               ],
+                                               [
+                                                       'code' => 'parentheses',
+                                                       'key' => 'parentheses',
+                                                       'params' => [ 'foobar', $I => 'param' ],
+                                                       'module' => 'status',
                                                ],
+                                               $I => 'error',
                                        ],
                                        'warnings' => [
-                                               'status' => [
-                                                       [
-                                                               'code' => 'mainpage',
-                                                               'key' => 'mainpage',
-                                                               'params' => [ $I => 'param' ]
-                                                       ],
-                                                       [
-                                                               'code' => 'parentheses',
-                                                               'key' => 'parentheses',
-                                                               'params' => [ 'foobar', $I => 'param' ]
-                                                       ],
-                                                       [
-                                                               'code' => 'overriddenCode',
-                                                               'key' => 'mainpage',
-                                                               'params' => [ $I => 'param' ],
-                                                               'overriddenData' => true
-                                                       ],
-                                                       $I => 'warning',
+                                               [
+                                                       'code' => 'mainpage',
+                                                       'key' => 'mainpage',
+                                                       'params' => [ $I => 'param' ],
+                                                       'module' => 'status',
                                                ],
+                                               [
+                                                       'code' => 'parentheses',
+                                                       'key' => 'parentheses',
+                                                       'params' => [ 'foobar', $I => 'param' ],
+                                                       'module' => 'status',
+                                               ],
+                                               [
+                                                       'code' => 'overriddenCode',
+                                                       'key' => 'mainpage',
+                                                       'params' => [ $I => 'param' ],
+                                                       'data' => $overriddenData,
+                                                       'module' => 'status',
+                                               ],
+                                               $I => 'warning',
                                        ],
                                ],
                        ],
                        [ 'none', 'fr', true,
                                [
                                        'errors' => [
-                                               'err' => [
-                                                       [ 'code' => 'mainpage' ],
-                                                       $I => 'error',
-                                               ],
+                                               [ 'code' => 'mainpage', 'module' => 'err' ],
+                                               $I => 'error',
                                        ],
                                        'warnings' => [
-                                               'string' => [
-                                                       [ 'code' => 'mainpage' ],
-                                                       $I => 'warning',
-                                               ],
+                                               [ 'code' => 'mainpage', 'module' => 'string' ],
+                                               $I => 'warning',
                                        ],
                                ],
                                [
                                        'errors' => [
-                                               'errWithData' => [
-                                                       [ 'code' => 'overriddenCode', 'overriddenData' => true ],
-                                                       $I => 'error',
-                                               ],
+                                               [ 'code' => 'overriddenCode', 'data' => $overriddenData,
+                                                       'module' => 'errWithData' ],
+                                               $I => 'error',
                                        ],
                                        'warnings' => [
-                                               'messageWithData' => [
-                                                       [ 'code' => 'overriddenCode', 'overriddenData' => true ],
-                                                       $I => 'warning',
-                                               ],
-                                               'message' => [
-                                                       [ 'code' => 'mainpage' ],
-                                                       $I => 'warning',
-                                               ],
-                                               'foo' => [
-                                                       [ 'code' => 'mainpage' ],
-                                                       [ 'code' => 'parentheses' ],
-                                                       $I => 'warning',
-                                               ],
+                                               [ 'code' => 'mainpage', 'module' => 'foo' ],
+                                               [ 'code' => 'parentheses', 'module' => 'foo' ],
+                                               [ 'code' => 'mainpage', 'module' => 'message' ],
+                                               [ 'code' => 'overriddenCode', 'data' => $overriddenData,
+                                                       'module' => 'messageWithData' ],
+                                               $I => 'warning',
                                        ],
                                ],
                                [
                                        'errors' => [
-                                               'status' => [
-                                                       [ 'code' => 'mainpage' ],
-                                                       [ 'code' => 'parentheses' ],
-                                                       $I => 'error',
-                                               ],
+                                               [ 'code' => 'mainpage', 'module' => 'status' ],
+                                               [ 'code' => 'parentheses', 'module' => 'status' ],
+                                               $I => 'error',
                                        ],
                                        'warnings' => [
-                                               'status' => [
-                                                       [ 'code' => 'mainpage' ],
-                                                       [ 'code' => 'parentheses' ],
-                                                       [ 'code' => 'overriddenCode', 'overriddenData' => true ],
-                                                       $I => 'warning',
-                                               ],
+                                               [ 'code' => 'mainpage', 'module' => 'status' ],
+                                               [ 'code' => 'parentheses', 'module' => 'status' ],
+                                               [ 'code' => 'overriddenCode', 'data' => $overriddenData, 'module' => 'status' ],
+                                               $I => 'warning',
                                        ],
                                ],
                        ],
@@ -302,7 +348,14 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase {
                $result = new ApiResult( 8388608 );
                $formatter = new ApiErrorFormatter_BackCompat( $result );
 
+               $this->assertSame( 'en', $formatter->getLanguage()->getCode() );
+
+               $this->assertSame( [], $formatter->arrayFromStatus( Status::newGood() ) );
+
                $formatter->addWarning( 'string', 'mainpage' );
+               $formatter->addWarning( 'raw',
+                       new RawMessage( 'Blah <kbd>kbd</kbd> <b>&lt;X&gt;</b> &#x1f61e;' )
+               );
                $formatter->addError( 'err', 'mainpage' );
                $this->assertSame( [
                        'error' => [
@@ -310,6 +363,10 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase {
                                'info' => $mainpagePlain,
                        ],
                        'warnings' => [
+                               'raw' => [
+                                       'warnings' => 'Blah "kbd" <X> 😞',
+                                       ApiResult::META_CONTENT => 'warnings',
+                               ],
                                'string' => [
                                        'warnings' => $mainpagePlain,
                                        ApiResult::META_CONTENT => 'warnings',
@@ -321,12 +378,13 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase {
                $result->reset();
                $formatter->addWarning( 'foo', 'mainpage' );
                $formatter->addWarning( 'foo', 'mainpage' );
-               $formatter->addWarning( 'foo', [ 'parentheses', 'foobar' ] );
+               $formatter->addWarning( 'xxx+foo', [ 'parentheses', 'foobar' ] );
                $msg1 = wfMessage( 'mainpage' );
                $formatter->addWarning( 'message', $msg1 );
                $msg2 = new ApiMessage( 'mainpage', 'overriddenCode', [ 'overriddenData' => true ] );
                $formatter->addWarning( 'messageWithData', $msg2 );
                $formatter->addError( 'errWithData', $msg2 );
+               $formatter->addWarning( null, 'mainpage' );
                $this->assertSame( [
                        'error' => [
                                'code' => 'overriddenCode',
@@ -334,6 +392,10 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase {
                                'overriddenData' => true,
                        ],
                        'warnings' => [
+                               'unknown' => [
+                                       'warnings' => $mainpagePlain,
+                                       ApiResult::META_CONTENT => 'warnings',
+                               ],
                                'messageWithData' => [
                                        'warnings' => $mainpagePlain,
                                        ApiResult::META_CONTENT => 'warnings',
@@ -350,6 +412,22 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase {
                        ApiResult::META_TYPE => 'assoc',
                ], $result->getResultData(), 'Complex test' );
 
+               $this->assertSame(
+                       [
+                               'code' => 'mainpage',
+                               'info' => 'Main Page',
+                       ],
+                       $formatter->formatMessage( $msg1 )
+               );
+               $this->assertSame(
+                       [
+                               'code' => 'overriddenCode',
+                               'info' => 'Main Page',
+                               'overriddenData' => true,
+                       ],
+                       $formatter->formatMessage( $msg2 )
+               );
+
                $result->reset();
                $status = Status::newGood();
                $status->warning( 'mainpage' );
@@ -377,14 +455,16 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase {
                $this->assertSame(
                        [
                                [
-                                       'type' => 'error',
                                        'message' => 'mainpage',
-                                       'params' => [ $I => 'param' ]
+                                       'params' => [ $I => 'param' ],
+                                       'code' => 'mainpage',
+                                       'type' => 'error',
                                ],
                                [
-                                       'type' => 'error',
                                        'message' => 'parentheses',
-                                       'params' => [ 'foobar', $I => 'param' ]
+                                       'params' => [ 'foobar', $I => 'param' ],
+                                       'code' => 'parentheses',
+                                       'type' => 'error',
                                ],
                                $I => 'error',
                        ],
@@ -394,24 +474,28 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase {
                $this->assertSame(
                        [
                                [
-                                       'type' => 'warning',
                                        'message' => 'mainpage',
-                                       'params' => [ $I => 'param' ]
+                                       'params' => [ $I => 'param' ],
+                                       'code' => 'mainpage',
+                                       'type' => 'warning',
                                ],
                                [
-                                       'type' => 'warning',
                                        'message' => 'parentheses',
-                                       'params' => [ 'foobar', $I => 'param' ]
+                                       'params' => [ 'foobar', $I => 'param' ],
+                                       'code' => 'parentheses',
+                                       'type' => 'warning',
                                ],
                                [
                                        'message' => 'mainpage',
                                        'params' => [ $I => 'param' ],
-                                       'type' => 'warning'
+                                       'code' => 'mainpage',
+                                       'type' => 'warning',
                                ],
                                [
                                        'message' => 'mainpage',
                                        'params' => [ $I => 'param' ],
-                                       'type' => 'warning'
+                                       'code' => 'overriddenCode',
+                                       'type' => 'warning',
                                ],
                                $I => 'warning',
                        ],
index c111949..c9a3428 100644 (file)
@@ -53,8 +53,8 @@ class ApiMainTest extends ApiTestCase {
                                'assert' => $assert,
                        ], null, null, $user );
                        $this->assertFalse( $error ); // That no error was expected
-               } catch ( UsageException $e ) {
-                       $this->assertEquals( $e->getCodeString(), $error );
+               } catch ( ApiUsageException $e ) {
+                       $this->assertTrue( self::apiExceptionHasCode( $e, $error ) );
                }
        }
 
@@ -76,8 +76,8 @@ class ApiMainTest extends ApiTestCase {
                                'assertuser' => $user->getName() . 'X',
                        ], null, null, $user );
                        $this->fail( 'Expected exception not thrown' );
-               } catch ( UsageException $e ) {
-                       $this->assertEquals( $e->getCodeString(), 'assertnameduserfailed' );
+               } catch ( ApiUsageException $e ) {
+                       $this->assertTrue( self::apiExceptionHasCode( $e, 'assertnameduserfailed' ) );
                }
        }
 
@@ -305,4 +305,274 @@ class ApiMainTest extends ApiTestCase {
                $main = new ApiMain( new FauxRequest( [ 'action' => 'query', 'meta' => 'siteinfo' ] ) );
                $this->assertTrue( $main->lacksSameOriginSecurity(), 'Hook, should lack security' );
        }
+
+       /**
+        * Test proper creation of the ApiErrorFormatter
+        * @covers ApiMain::__construct
+        * @dataProvider provideApiErrorFormatterCreation
+        * @param array $request Request parameters
+        * @param array $expect Expected data
+        *  - uselang: ApiMain language
+        *  - class: ApiErrorFormatter class
+        *  - lang: ApiErrorFormatter language
+        *  - format: ApiErrorFormatter format
+        *  - usedb: ApiErrorFormatter use-database flag
+        */
+       public function testApiErrorFormatterCreation( array $request, array $expect ) {
+               $context = new RequestContext();
+               $context->setRequest( new FauxRequest( $request ) );
+               $context->setLanguage( 'ru' );
+
+               $main = new ApiMain( $context );
+               $formatter = $main->getErrorFormatter();
+               $wrappedFormatter = TestingAccessWrapper::newFromObject( $formatter );
+
+               $this->assertSame( $expect['uselang'], $main->getLanguage()->getCode() );
+               $this->assertInstanceOf( $expect['class'], $formatter );
+               $this->assertSame( $expect['lang'], $formatter->getLanguage()->getCode() );
+               $this->assertSame( $expect['format'], $wrappedFormatter->format );
+               $this->assertSame( $expect['usedb'], $wrappedFormatter->useDB );
+       }
+
+       public static function provideApiErrorFormatterCreation() {
+               global $wgContLang;
+
+               return [
+                       'Default (BC)' => [ [], [
+                               'uselang' => 'ru',
+                               'class' => ApiErrorFormatter_BackCompat::class,
+                               'lang' => 'en',
+                               'format' => 'none',
+                               'usedb' => false,
+                       ] ],
+                       'BC ignores fields' => [ [ 'errorlang' => 'de', 'errorsuselocal' => 1 ], [
+                               'uselang' => 'ru',
+                               'class' => ApiErrorFormatter_BackCompat::class,
+                               'lang' => 'en',
+                               'format' => 'none',
+                               'usedb' => false,
+                       ] ],
+                       'Explicit BC' => [ [ 'errorformat' => 'bc' ], [
+                               'uselang' => 'ru',
+                               'class' => ApiErrorFormatter_BackCompat::class,
+                               'lang' => 'en',
+                               'format' => 'none',
+                               'usedb' => false,
+                       ] ],
+                       'Basic' => [ [ 'errorformat' => 'wikitext' ], [
+                               'uselang' => 'ru',
+                               'class' => ApiErrorFormatter::class,
+                               'lang' => 'ru',
+                               'format' => 'wikitext',
+                               'usedb' => false,
+                       ] ],
+                       'Follows uselang' => [ [ 'uselang' => 'fr', 'errorformat' => 'plaintext' ], [
+                               'uselang' => 'fr',
+                               'class' => ApiErrorFormatter::class,
+                               'lang' => 'fr',
+                               'format' => 'plaintext',
+                               'usedb' => false,
+                       ] ],
+                       'Explicitly follows uselang' => [
+                               [ 'uselang' => 'fr', 'errorlang' => 'uselang', 'errorformat' => 'plaintext' ],
+                               [
+                                       'uselang' => 'fr',
+                                       'class' => ApiErrorFormatter::class,
+                                       'lang' => 'fr',
+                                       'format' => 'plaintext',
+                                       'usedb' => false,
+                               ]
+                       ],
+                       'uselang=content' => [
+                               [ 'uselang' => 'content', 'errorformat' => 'plaintext' ],
+                               [
+                                       'uselang' => $wgContLang->getCode(),
+                                       'class' => ApiErrorFormatter::class,
+                                       'lang' => $wgContLang->getCode(),
+                                       'format' => 'plaintext',
+                                       'usedb' => false,
+                               ]
+                       ],
+                       'errorlang=content' => [
+                               [ 'errorlang' => 'content', 'errorformat' => 'plaintext' ],
+                               [
+                                       'uselang' => 'ru',
+                                       'class' => ApiErrorFormatter::class,
+                                       'lang' => $wgContLang->getCode(),
+                                       'format' => 'plaintext',
+                                       'usedb' => false,
+                               ]
+                       ],
+                       'Explicit parameters' => [
+                               [ 'errorlang' => 'de', 'errorformat' => 'html', 'errorsuselocal' => 1 ],
+                               [
+                                       'uselang' => 'ru',
+                                       'class' => ApiErrorFormatter::class,
+                                       'lang' => 'de',
+                                       'format' => 'html',
+                                       'usedb' => true,
+                               ]
+                       ],
+                       'Explicit parameters override uselang' => [
+                               [ 'errorlang' => 'de', 'uselang' => 'fr', 'errorformat' => 'raw' ],
+                               [
+                                       'uselang' => 'fr',
+                                       'class' => ApiErrorFormatter::class,
+                                       'lang' => 'de',
+                                       'format' => 'raw',
+                                       'usedb' => false,
+                               ]
+                       ],
+                       'Bogus language doesn\'t explode' => [
+                               [ 'errorlang' => '<bogus1>', 'uselang' => '<bogus2>', 'errorformat' => 'none' ],
+                               [
+                                       'uselang' => 'en',
+                                       'class' => ApiErrorFormatter::class,
+                                       'lang' => 'en',
+                                       'format' => 'none',
+                                       'usedb' => false,
+                               ]
+                       ],
+                       'Bogus format doesn\'t explode' => [ [ 'errorformat' => 'bogus' ], [
+                               'uselang' => 'ru',
+                               'class' => ApiErrorFormatter_BackCompat::class,
+                               'lang' => 'en',
+                               'format' => 'none',
+                               'usedb' => false,
+                       ] ],
+               ];
+       }
+
+       /**
+        * @covers ApiMain::errorMessagesFromException
+        * @covers ApiMain::substituteResultWithError
+        * @dataProvider provideExceptionErrors
+        * @param Exception $exception
+        * @param array $expectReturn
+        * @param array $expectResult
+        */
+       public function testExceptionErrors( $error, $expectReturn, $expectResult ) {
+               $context = new RequestContext();
+               $context->setRequest( new FauxRequest( [ 'errorformat' => 'plaintext' ] ) );
+               $context->setLanguage( 'en' );
+               $context->setConfig( new MultiConfig( [
+                       new HashConfig( [ 'ShowHostnames' => true, 'ShowSQLErrors' => false ] ),
+                       $context->getConfig()
+               ] ) );
+
+               $main = new ApiMain( $context );
+               $main->addWarning( new RawMessage( 'existing warning' ), 'existing-warning' );
+               $main->addError( new RawMessage( 'existing error' ), 'existing-error' );
+
+               $ret = TestingAccessWrapper::newFromObject( $main )->substituteResultWithError( $error );
+               $this->assertSame( $expectReturn, $ret );
+
+               // PHPUnit sometimes adds some SplObjectStorage garbage to the arrays,
+               // so let's try ->assertEquals().
+               $this->assertEquals(
+                       $expectResult,
+                       $main->getResult()->getResultData( [], [ 'Strip' => 'all' ] )
+               );
+       }
+
+       // Not static so $this->getMock() can be used
+       public function provideExceptionErrors() {
+               $reqId = WebRequest::getRequestId();
+               $doclink = wfExpandUrl( wfScript( 'api' ) );
+
+               $ex = new InvalidArgumentException( 'Random exception' );
+               $trace = wfMessage( 'api-exception-trace',
+                       get_class( $ex ),
+                       $ex->getFile(),
+                       $ex->getLine(),
+                       MWExceptionHandler::getRedactedTraceAsString( $ex )
+               )->inLanguage( 'en' )->useDatabase( false )->text();
+
+               $dbex = new DBQueryError( $this->getMock( 'IDatabase' ), 'error', 1234, 'SELECT 1', __METHOD__ );
+               $dbtrace = wfMessage( 'api-exception-trace',
+                       get_class( $dbex ),
+                       $dbex->getFile(),
+                       $dbex->getLine(),
+                       MWExceptionHandler::getRedactedTraceAsString( $dbex )
+               )->inLanguage( 'en' )->useDatabase( false )->text();
+
+               $apiEx1 = new ApiUsageException( null,
+                       StatusValue::newFatal( new ApiRawMessage( 'An error', 'sv-error1' ) ) );
+               TestingAccessWrapper::newFromObject( $apiEx1 )->modulePath = 'foo+bar';
+               $apiEx1->getStatusValue()->warning( new ApiRawMessage( 'A warning', 'sv-warn1' ) );
+               $apiEx1->getStatusValue()->warning( new ApiRawMessage( 'Another warning', 'sv-warn2' ) );
+               $apiEx1->getStatusValue()->fatal( new ApiRawMessage( 'Another error', 'sv-error2' ) );
+
+               return [
+                       [
+                               $ex,
+                               [ 'existing-error', 'internal_api_error_InvalidArgumentException' ],
+                               [
+                                       'warnings' => [
+                                               [ 'code' => 'existing-warning', 'text' => 'existing warning', 'module' => 'main' ],
+                                       ],
+                                       'errors' => [
+                                               [ 'code' => 'existing-error', 'text' => 'existing error', 'module' => 'main' ],
+                                               [
+                                                       'code' => 'internal_api_error_InvalidArgumentException',
+                                                       'text' => "[$reqId] Exception caught: Random exception",
+                                               ]
+                                       ],
+                                       'trace' => $trace,
+                                       'servedby' => wfHostname(),
+                               ]
+                       ],
+                       [
+                               $dbex,
+                               [ 'existing-error', 'internal_api_error_DBQueryError' ],
+                               [
+                                       'warnings' => [
+                                               [ 'code' => 'existing-warning', 'text' => 'existing warning', 'module' => 'main' ],
+                                       ],
+                                       'errors' => [
+                                               [ 'code' => 'existing-error', 'text' => 'existing error', 'module' => 'main' ],
+                                               [
+                                                       'code' => 'internal_api_error_DBQueryError',
+                                                       'text' => "[$reqId] Database query error.",
+                                               ]
+                                       ],
+                                       'trace' => $dbtrace,
+                                       'servedby' => wfHostname(),
+                               ]
+                       ],
+                       [
+                               new UsageException( 'Usage exception!', 'ue', 0, [ 'foo' => 'bar' ] ),
+                               [ 'existing-error', 'ue' ],
+                               [
+                                       'warnings' => [
+                                               [ 'code' => 'existing-warning', 'text' => 'existing warning', 'module' => 'main' ],
+                                       ],
+                                       'errors' => [
+                                               [ 'code' => 'existing-error', 'text' => 'existing error', 'module' => 'main' ],
+                                               [ 'code' => 'ue', 'text' => "Usage exception!", 'data' => [ 'foo' => 'bar' ] ]
+                                       ],
+                                       'docref' => "See $doclink for API usage.",
+                                       'servedby' => wfHostname(),
+                               ]
+                       ],
+                       [
+                               $apiEx1,
+                               [ 'existing-error', 'sv-error1', 'sv-error2' ],
+                               [
+                                       'warnings' => [
+                                               [ 'code' => 'existing-warning', 'text' => 'existing warning', 'module' => 'main' ],
+                                               [ 'code' => 'sv-warn1', 'text' => 'A warning', 'module' => 'foo+bar' ],
+                                               [ 'code' => 'sv-warn2', 'text' => 'Another warning', 'module' => 'foo+bar' ],
+                                       ],
+                                       'errors' => [
+                                               [ 'code' => 'existing-error', 'text' => 'existing error', 'module' => 'main' ],
+                                               [ 'code' => 'sv-error1', 'text' => 'An error', 'module' => 'foo+bar' ],
+                                               [ 'code' => 'sv-error2', 'text' => 'Another error', 'module' => 'foo+bar' ],
+                                       ],
+                                       'docref' => "See $doclink for API usage.",
+                                       'servedby' => wfHostname(),
+                               ]
+                       ],
+               ];
+       }
 }
index 8764b41..e405b3b 100644 (file)
@@ -23,6 +23,56 @@ class ApiMessageTest extends MediaWikiTestCase {
                );
        }
 
+       /**
+        * @covers ApiMessageTrait
+        */
+       public function testCodeDefaults() {
+               $msg = new ApiMessage( 'foo' );
+               $this->assertSame( 'foo', $msg->getApiCode() );
+
+               $msg = new ApiMessage( 'apierror-bar' );
+               $this->assertSame( 'bar', $msg->getApiCode() );
+
+               $msg = new ApiMessage( 'apiwarn-baz' );
+               $this->assertSame( 'baz', $msg->getApiCode() );
+
+               // BC case
+               $msg = new ApiMessage( 'actionthrottledtext' );
+               $this->assertSame( 'ratelimited', $msg->getApiCode() );
+
+               $msg = new ApiMessage( [ 'apierror-missingparam', 'param' ] );
+               $this->assertSame( 'noparam', $msg->getApiCode() );
+       }
+
+       /**
+        * @covers ApiMessageTrait
+        * @dataProvider provideInvalidCode
+        * @param mixed $code
+        */
+       public function testInvalidCode( $code ) {
+               $msg = new ApiMessage( 'foo' );
+               try {
+                       $msg->setApiCode( $code );
+                       $this->fail( 'Expected exception not thrown' );
+               } catch ( InvalidArgumentException $ex ) {
+                       $this->assertTrue( true );
+               }
+
+               try {
+                       new ApiMessage( 'foo', $code );
+                       $this->fail( 'Expected exception not thrown' );
+               } catch ( InvalidArgumentException $ex ) {
+                       $this->assertTrue( true );
+               }
+       }
+
+       public static function provideInvalidCode() {
+               return [
+                       [ '' ],
+                       [ 42 ],
+               ];
+       }
+
        /**
         * @covers ApiMessage
         * @covers ApiMessageTrait
@@ -105,14 +155,32 @@ class ApiMessageTest extends MediaWikiTestCase {
         * @covers ApiMessage::create
         */
        public function testApiMessageCreate() {
-               $this->assertInstanceOf( 'ApiMessage', ApiMessage::create( new Message( 'mainpage' ) ) );
-               $this->assertInstanceOf( 'ApiRawMessage', ApiMessage::create( new RawMessage( 'mainpage' ) ) );
-               $this->assertInstanceOf( 'ApiMessage', ApiMessage::create( 'mainpage' ) );
+               $this->assertInstanceOf( ApiMessage::class, ApiMessage::create( new Message( 'mainpage' ) ) );
+               $this->assertInstanceOf(
+                       ApiRawMessage::class, ApiMessage::create( new RawMessage( 'mainpage' ) )
+               );
+               $this->assertInstanceOf( ApiMessage::class, ApiMessage::create( 'mainpage' ) );
+
+               $msg = new ApiMessage( [ 'parentheses', 'foobar' ] );
+               $msg2 = new Message( 'parentheses', [ 'foobar' ] );
 
-               $msg = new ApiMessage( 'mainpage' );
                $this->assertSame( $msg, ApiMessage::create( $msg ) );
+               $this->assertEquals( $msg, ApiMessage::create( $msg2 ) );
+               $this->assertEquals( $msg, ApiMessage::create( [ 'parentheses', 'foobar' ] ) );
+               $this->assertEquals( $msg,
+                       ApiMessage::create( [ 'message' => 'parentheses', 'params' => [ 'foobar' ] ] )
+               );
+               $this->assertSame( $msg,
+                       ApiMessage::create( [ 'message' => $msg, 'params' => [ 'xxx' ] ] )
+               );
+               $this->assertEquals( $msg,
+                       ApiMessage::create( [ 'message' => $msg2, 'params' => [ 'xxx' ] ] )
+               );
+               $this->assertSame( $msg,
+                       ApiMessage::create( [ 'message' => $msg ] )
+               );
 
-               $msg = new ApiRawMessage( 'mainpage' );
+               $msg = new ApiRawMessage( [ 'parentheses', 'foobar' ] );
                $this->assertSame( $msg, ApiMessage::create( $msg ) );
        }
 
index 0a577c1..ef70626 100644 (file)
@@ -30,7 +30,7 @@ class ApiOptionsTest extends MediaWikiLangTestCase {
                $this->mUserMock->expects( $this->any() )
                        ->method( 'getEffectiveGroups' )->will( $this->returnValue( [ '*', 'user' ] ) );
                $this->mUserMock->expects( $this->any() )
-                       ->method( 'isAllowed' )->will( $this->returnValue( true ) );
+                       ->method( 'isAllowedAny' )->will( $this->returnValue( true ) );
 
                // Set up callback for User::getOptionKinds
                $this->mUserMock->expects( $this->any() )
@@ -146,7 +146,7 @@ class ApiOptionsTest extends MediaWikiLangTestCase {
        }
 
        /**
-        * @expectedException UsageException
+        * @expectedException ApiUsageException
         */
        public function testNoToken() {
                $request = $this->getSampleRequest( [ 'token' => null ] );
@@ -163,13 +163,11 @@ class ApiOptionsTest extends MediaWikiLangTestCase {
                        $request = $this->getSampleRequest();
 
                        $this->executeQuery( $request );
-               } catch ( UsageException $e ) {
-                       $this->assertEquals( 'notloggedin', $e->getCodeString() );
-                       $this->assertEquals( 'Anonymous users cannot change preferences', $e->getMessage() );
-
+               } catch ( ApiUsageException $e ) {
+                       $this->assertTrue( ApiTestCase::apiExceptionHasCode( $e, 'notloggedin' ) );
                        return;
                }
-               $this->fail( "UsageException was not thrown" );
+               $this->fail( "ApiUsageException was not thrown" );
        }
 
        public function testNoOptionname() {
@@ -177,13 +175,11 @@ class ApiOptionsTest extends MediaWikiLangTestCase {
                        $request = $this->getSampleRequest( [ 'optionvalue' => '1' ] );
 
                        $this->executeQuery( $request );
-               } catch ( UsageException $e ) {
-                       $this->assertEquals( 'nooptionname', $e->getCodeString() );
-                       $this->assertEquals( 'The optionname parameter must be set', $e->getMessage() );
-
+               } catch ( ApiUsageException $e ) {
+                       $this->assertTrue( ApiTestCase::apiExceptionHasCode( $e, 'nooptionname' ) );
                        return;
                }
-               $this->fail( "UsageException was not thrown" );
+               $this->fail( "ApiUsageException was not thrown" );
        }
 
        public function testNoChanges() {
@@ -200,13 +196,11 @@ class ApiOptionsTest extends MediaWikiLangTestCase {
                        $request = $this->getSampleRequest();
 
                        $this->executeQuery( $request );
-               } catch ( UsageException $e ) {
-                       $this->assertEquals( 'nochanges', $e->getCodeString() );
-                       $this->assertEquals( 'No changes were requested', $e->getMessage() );
-
+               } catch ( ApiUsageException $e ) {
+                       $this->assertTrue( ApiTestCase::apiExceptionHasCode( $e, 'nochanges' ) );
                        return;
                }
-               $this->fail( "UsageException was not thrown" );
+               $this->fail( "ApiUsageException was not thrown" );
        }
 
        public function testReset() {
@@ -400,7 +394,7 @@ class ApiOptionsTest extends MediaWikiLangTestCase {
                        'options' => 'success',
                        'warnings' => [
                                'options' => [
-                                       'warnings' => "Validation error for 'special': cannot be set by this module"
+                                       'warnings' => "Validation error for \"special\": cannot be set by this module."
                                ]
                        ]
                ], $response );
@@ -423,7 +417,7 @@ class ApiOptionsTest extends MediaWikiLangTestCase {
                        'options' => 'success',
                        'warnings' => [
                                'options' => [
-                                       'warnings' => "Validation error for 'unknownOption': not a valid preference"
+                                       'warnings' => "Validation error for \"unknownOption\": not a valid preference."
                                ]
                        ]
                ], $response );
index b72a4f8..f01a670 100644 (file)
@@ -23,12 +23,10 @@ class ApiParseTest extends ApiTestCase {
                                'page' => $somePage ] );
 
                        $this->fail( "API did not return an error when parsing a nonexistent page" );
-               } catch ( UsageException $ex ) {
-                       $this->assertEquals(
-                               'missingtitle',
-                               $ex->getCodeString(),
+               } catch ( ApiUsageException $ex ) {
+                       $this->assertTrue( ApiTestCase::apiExceptionHasCode( $ex, 'missingtitle' ),
                                "Parse request for nonexistent page must give 'missingtitle' error: "
-                                       . var_export( $ex->getMessageArray(), true )
+                                       . var_export( self::getErrorFormatter()->arrayFromStatus( $ex->getStatusValue() ), true )
                        );
                }
        }
index eaeb3ae..0a2cd83 100644 (file)
@@ -1498,7 +1498,7 @@ class ApiQueryWatchlistIntegrationTest extends ApiTestCase {
                $otherUser->setOption( 'watchlisttoken', '1234567890' );
                $otherUser->saveSettings();
 
-               $this->setExpectedException( UsageException::class, 'Incorrect watchlist token provided' );
+               $this->setExpectedException( ApiUsageException::class, 'Incorrect watchlist token provided' );
 
                $this->doListWatchlistRequest( [
                        'wlowner' => $otherUser->getName(),
@@ -1507,7 +1507,7 @@ class ApiQueryWatchlistIntegrationTest extends ApiTestCase {
        }
 
        public function testOwnerAndTokenParams_noWatchlistTokenSet() {
-               $this->setExpectedException( UsageException::class, 'Incorrect watchlist token provided' );
+               $this->setExpectedException( ApiUsageException::class, 'Incorrect watchlist token provided' );
 
                $this->doListWatchlistRequest( [
                        'wlowner' => $this->getNonLoggedInTestUser()->getName(),
index d6f315d..0f01664 100644 (file)
@@ -503,7 +503,7 @@ class ApiQueryWatchlistRawIntegrationTest extends ApiTestCase {
                $otherUser->setOption( 'watchlisttoken', '1234567890' );
                $otherUser->saveSettings();
 
-               $this->setExpectedException( UsageException::class, 'Incorrect watchlist token provided' );
+               $this->setExpectedException( ApiUsageException::class, 'Incorrect watchlist token provided' );
 
                $this->doListWatchlistRawRequest( [
                        'wrowner' => $otherUser->getName(),
@@ -512,7 +512,7 @@ class ApiQueryWatchlistRawIntegrationTest extends ApiTestCase {
        }
 
        public function testOwnerAndTokenParams_userHasNoWatchlistToken() {
-               $this->setExpectedException( UsageException::class, 'Incorrect watchlist token provided' );
+               $this->setExpectedException( ApiUsageException::class, 'Incorrect watchlist token provided' );
 
                $this->doListWatchlistRawRequest( [
                        'wrowner' => $this->getNotLoggedInTestUser()->getName(),
index 7e1f9d8..6b299c9 100644 (file)
@@ -3,6 +3,8 @@
 abstract class ApiTestCase extends MediaWikiLangTestCase {
        protected static $apiUrl;
 
+       protected static $errorFormatter = null;
+
        /**
         * @var ApiTestContext
         */
@@ -196,6 +198,26 @@ abstract class ApiTestCase extends MediaWikiLangTestCase {
                return $data[0]['tokens'];
        }
 
+       protected static function getErrorFormatter() {
+               if ( self::$errorFormatter === null ) {
+                       self::$errorFormatter = new ApiErrorFormatter(
+                               new ApiResult( false ),
+                               Language::factory( 'en' ),
+                               'none'
+                       );
+               }
+               return self::$errorFormatter;
+       }
+
+       public static function apiExceptionHasCode( ApiUsageException $ex, $code ) {
+               return (bool)array_filter(
+                       self::getErrorFormatter()->arrayFromStatus( $ex->getStatusValue() ),
+                       function ( $e ) use ( $code ) {
+                               return is_array( $e ) && $e['code'] === $code;
+                       }
+               );
+       }
+
        public function testApiTestGroup() {
                $groups = PHPUnit_Util_Test::getGroups( get_class( $this ) );
                $constraint = PHPUnit_Framework_Assert::logicalOr(
index b63bf2e..971b63c 100644 (file)
@@ -14,7 +14,7 @@ class ApiUnblockTest extends ApiTestCase {
        }
 
        /**
-        * @expectedException UsageException
+        * @expectedException ApiUsageException
         */
        public function testWithNoToken() {
                $this->doApiRequest(
index de2b56b..9b79e6c 100644 (file)
@@ -67,9 +67,9 @@ class ApiUploadTest extends ApiTestCaseUpload {
                        $this->doApiRequest( [
                                'action' => 'upload'
                        ] );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
-                       $this->assertEquals( "The token parameter must be set", $e->getMessage() );
+                       $this->assertEquals( 'The "token" parameter must be set', $e->getMessage() );
                }
                $this->assertTrue( $exception, "Got exception" );
        }
@@ -83,7 +83,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                        $this->doApiRequestWithToken( [
                                'action' => 'upload',
                        ], $session, self::$users['uploader']->getUser() );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                        $this->assertEquals( "One of the parameters filekey, file, url is required",
                                $e->getMessage() );
@@ -129,7 +129,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                try {
                        list( $result, , ) = $this->doApiRequestWithToken( $params, $session,
                                self::$users['uploader']->getUser() );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                }
                $this->assertTrue( isset( $result['upload'] ) );
@@ -168,7 +168,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                $exception = false;
                try {
                        $this->doApiRequestWithToken( $params, $session, self::$users['uploader']->getUser() );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $this->assertContains( 'The file you submitted was empty', $e->getMessage() );
                        $exception = true;
                }
@@ -218,7 +218,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                try {
                        list( $result, , $session ) = $this->doApiRequestWithToken( $params, $session,
                                self::$users['uploader']->getUser() );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                }
                $this->assertTrue( isset( $result['upload'] ) );
@@ -235,7 +235,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                try {
                        list( $result, , ) = $this->doApiRequestWithToken( $params, $session,
                                self::$users['uploader']->getUser() ); // FIXME: leaks a temporary file
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                }
                $this->assertTrue( isset( $result['upload'] ) );
@@ -289,7 +289,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                try {
                        list( $result, , $session ) = $this->doApiRequestWithToken( $params, $session,
                                self::$users['uploader']->getUser() );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                }
                $this->assertTrue( isset( $result['upload'] ) );
@@ -314,7 +314,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                try {
                        list( $result ) = $this->doApiRequestWithToken( $params, $session,
                                self::$users['uploader']->getUser() ); // FIXME: leaks a temporary file
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                }
                $this->assertTrue( isset( $result['upload'] ) );
@@ -371,7 +371,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                try {
                        list( $result, , $session ) = $this->doApiRequestWithToken( $params, $session,
                                self::$users['uploader']->getUser() ); // FIXME: leaks a temporary file
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                }
                $this->assertFalse( $exception );
@@ -400,12 +400,12 @@ class ApiUploadTest extends ApiTestCaseUpload {
                try {
                        list( $result ) = $this->doApiRequestWithToken( $params, $session,
                                self::$users['uploader']->getUser() );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                }
                $this->assertTrue( isset( $result['upload'] ) );
                $this->assertEquals( 'Success', $result['upload']['result'] );
-               $this->assertFalse( $exception, "No UsageException exception." );
+               $this->assertFalse( $exception, "No ApiUsageException exception." );
 
                // clean up
                $this->deleteFileByFileName( $fileName );
@@ -476,7 +476,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                                try {
                                        list( $result, , $session ) = $this->doApiRequestWithToken( $params, $session,
                                                self::$users['uploader']->getUser() );
-                               } catch ( UsageException $e ) {
+                               } catch ( ApiUsageException $e ) {
                                        $this->markTestIncomplete( $e->getMessage() );
                                }
                                // Make sure we got a valid chunk continue:
@@ -504,7 +504,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                        try {
                                list( $result, , $session ) = $this->doApiRequestWithToken( $params, $session,
                                        self::$users['uploader']->getUser() );
-                       } catch ( UsageException $e ) {
+                       } catch ( ApiUsageException $e ) {
                                $this->markTestIncomplete( $e->getMessage() );
                        }
                        // Make sure we got a valid chunk continue:
@@ -544,7 +544,7 @@ class ApiUploadTest extends ApiTestCaseUpload {
                try {
                        list( $result ) = $this->doApiRequestWithToken( $params, $session,
                                self::$users['uploader']->getUser() );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                }
                $this->assertTrue( isset( $result['upload'] ) );
index 19afc14..0cd2707 100644 (file)
@@ -146,11 +146,11 @@ class ApiWatchTest extends ApiTestCase {
 
                        $this->assertArrayHasKey( 'rollback', $data[0] );
                        $this->assertArrayHasKey( 'title', $data[0]['rollback'] );
-               } catch ( UsageException $ue ) {
-                       if ( $ue->getCodeString() == 'onlyauthor' ) {
+               } catch ( ApiUsageException $ue ) {
+                       if ( self::apiExceptionHasCode( $ue, 'onlyauthor' ) ) {
                                $this->markTestIncomplete( "Only one author to 'Help:UTPage', cannot test rollback" );
                        } else {
-                               $this->fail( "Received error '" . $ue->getCodeString() . "'" );
+                               $this->fail( "Received error '" . $ue->getMessage() . "'" );
                        }
                }
        }
index d7db538..1407c10 100644 (file)
@@ -9,7 +9,11 @@ class MockApi extends ApiBase {
        public function __construct() {
        }
 
-       public function setWarning( $warning ) {
+       public function getModulePath() {
+               return $this->getModuleName();
+       }
+
+       public function addWarning( $warning, $code = null, $data = null ) {
                $this->warnings[] = $warning;
        }
 
index f5b50e5..9915a38 100644 (file)
@@ -12,4 +12,8 @@ class MockApiQueryBase extends ApiQueryBase {
        public function getModuleName() {
                return $this->name;
        }
+
+       public function getModulePath() {
+               return 'query+' . $this->getModuleName();
+       }
 }
index 0028bbb..3aa1db3 100644 (file)
@@ -133,12 +133,10 @@ class ApiFormatPhpTest extends ApiFormatTestBase {
                        $printer->closePrinter();
                        ob_end_clean();
                        $this->fail( 'Expected exception not thrown' );
-               } catch ( UsageException $ex ) {
+               } catch ( ApiUsageException $ex ) {
                        ob_end_clean();
-                       $this->assertSame(
-                               'This response cannot be represented using format=php. ' .
-                                       'See https://phabricator.wikimedia.org/T68776',
-                               $ex->getMessage(),
+                       $this->assertTrue(
+                               $ex->getStatusValue()->hasMessage( 'apierror-formatphp' ),
                                'Expected exception'
                        );
                }
index 3fef0b0..0f8c8ee 100644 (file)
@@ -105,11 +105,11 @@ class ApiFormatXmlTest extends ApiFormatTestBase {
                                [ 'includexmlnamespace' => 1 ] ],
 
                        // xslt param
-                       [ [], '<?xml version="1.0"?><api><warnings><xml xml:space="preserve">Invalid or non-existent stylesheet specified</xml></warnings></api>',
+                       [ [], '<?xml version="1.0"?><api><warnings><xml xml:space="preserve">Invalid or non-existent stylesheet specified.</xml></warnings></api>',
                                [ 'xslt' => 'DoesNotExist' ] ],
                        [ [], '<?xml version="1.0"?><api><warnings><xml xml:space="preserve">Stylesheet should be in the MediaWiki namespace.</xml></warnings></api>',
                                [ 'xslt' => 'ApiFormatXmlTest' ] ],
-                       [ [], '<?xml version="1.0"?><api><warnings><xml xml:space="preserve">Stylesheet should have .xsl extension.</xml></warnings></api>',
+                       [ [], '<?xml version="1.0"?><api><warnings><xml xml:space="preserve">Stylesheet should have &quot;.xsl&quot; extension.</xml></warnings></api>',
                                [ 'xslt' => 'MediaWiki:ApiFormatXmlTest' ] ],
                        [ [],
                                '<?xml version="1.0"?><?xml-stylesheet href="' .
index 8cb2327..9407edf 100644 (file)
@@ -99,11 +99,11 @@ class ApiQueryTest extends ApiTestCase {
                $exceptionCaught = false;
                try {
                        $this->assertEquals( $expected, $api->titlePartToKey( $titlePart, $namespace ) );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exceptionCaught = true;
                }
                $this->assertEquals( $expectException, $exceptionCaught,
-                       'UsageException thrown by titlePartToKey' );
+                       'ApiUsageException thrown by titlePartToKey' );
        }
 
        function provideTestTitlePartToKey() {
index 8b29983..4a3b90a 100644 (file)
@@ -130,7 +130,7 @@ class ResourceLoaderFileModuleTest extends ResourceLoaderTestCase {
                $modules = self::getModules();
                $rl = new ResourceLoaderFileModule( $modules[$name] );
                $rl->setName( $name );
-               $ctx = $this->getResourceLoaderContext( 'en', 'ltr' );
+               $ctx = $this->getResourceLoaderContext();
                $this->assertEquals( $rl->getScript( $ctx ), $expected );
        }
 
@@ -210,8 +210,14 @@ class ResourceLoaderFileModuleTest extends ResourceLoaderTestCase {
                ] );
                $expectedModule->setName( 'testing' );
 
-               $contextLtr = $this->getResourceLoaderContext( 'en', 'ltr' );
-               $contextRtl = $this->getResourceLoaderContext( 'he', 'rtl' );
+               $contextLtr = $this->getResourceLoaderContext( [
+                       'lang' => 'en',
+                       'dir' => 'ltr',
+               ] );
+               $contextRtl = $this->getResourceLoaderContext( [
+                       'lang' => 'he',
+                       'dir' => 'rtl',
+               ] );
 
                // Since we want to compare the effect of @noflip+@embed against the effect of just @embed, and
                // the @noflip annotations are always preserved, we need to strip them first.
@@ -282,9 +288,9 @@ class ResourceLoaderFileModuleTest extends ResourceLoaderTestCase {
                        'File has leading BOM'
                );
 
-               $contextLtr = $this->getResourceLoaderContext( 'en', 'ltr' );
+               $context = $this->getResourceLoaderContext();
                $this->assertEquals(
-                       $testModule->getStyles( $contextLtr ),
+                       $testModule->getStyles( $context ),
                        [ 'all' => ".efbbbf_bom_char_at_start_of_file {}\n" ],
                        'Leading BOM removed when concatenating files'
                );
index 179a8ed..84b56d4 100644 (file)
@@ -61,7 +61,10 @@ class ResourceLoaderImageTest extends ResourceLoaderTestCase {
                static $contexts = [];
 
                $image = $this->getTestImage( $imageName );
-               $context = $this->getResourceLoaderContext( $languageCode, $dirMap[$languageCode] );
+               $context = $this->getResourceLoaderContext( [
+                       'lang' => $languageCode,
+                       'dir' => $dirMap[$languageCode],
+               ] );
 
                $this->assertEquals( $image->getPath( $context ), $this->imagesPath . '/' . $path );
        }
@@ -87,7 +90,7 @@ class ResourceLoaderImageTest extends ResourceLoaderTestCase {
         * @covers ResourceLoaderImage::massageSvgPathdata
         */
        public function testGetImageData() {
-               $context = $this->getResourceLoaderContext( 'en', 'ltr' );
+               $context = $this->getResourceLoaderContext();
 
                $image = $this->getTestImage( 'remove' );
                $data = file_get_contents( $this->imagesPath . '/remove.svg' );
index c51217c..03e9c8f 100644 (file)
@@ -48,12 +48,22 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                );
 
                $this->assertEquals(
-                       $expected,
-                       $queryConditions,
+                       self::normalizeCondition( $expected ),
+                       self::normalizeCondition( $queryConditions ),
                        $message
                );
        }
 
+       private static function normalizeCondition( $conds ) {
+               return array_map(
+                       function ( $k, $v ) {
+                               return is_numeric( $k ) ? $v : "$k = $v";
+                       },
+                       array_keys( $conds ),
+                       $conds
+               );
+       }
+
        /** return false if condition begin with 'rc_timestamp ' */
        private static function filterOutRcTimestampCondition( $var ) {
                return ( false === strpos( $var, 'rc_timestamp ' ) );
@@ -63,8 +73,8 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                $this->assertConditions(
                        [ # expected
                                'rc_bot' => 0,
-                               0 => "rc_type != '6'",
-                               1 => "rc_namespace = '0'",
+                               "rc_type != '6'",
+                               "rc_namespace = '0'",
                        ],
                        [
                                'namespace' => NS_MAIN,
@@ -77,8 +87,8 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                $this->assertConditions(
                        [ # expected
                                'rc_bot' => 0,
-                               0 => "rc_type != '6'",
-                               1 => sprintf( "rc_namespace != '%s'", NS_MAIN ),
+                               "rc_type != '6'",
+                               "rc_namespace != '0'",
                        ],
                        [
                                'namespace' => NS_MAIN,
@@ -96,8 +106,8 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                $this->assertConditions(
                        [ # expected
                                'rc_bot' => 0,
-                               0 => "rc_type != '6'",
-                               1 => sprintf( "(rc_namespace = '%s' OR rc_namespace = '%s')", $ns1, $ns2 ),
+                               "rc_type != '6'",
+                               "(rc_namespace = '$ns1' OR rc_namespace = '$ns2')",
                        ],
                        [
                                'namespace' => $ns1,
@@ -115,8 +125,8 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                $this->assertConditions(
                        [ # expected
                                'rc_bot' => 0,
-                               0 => "rc_type != '6'",
-                               1 => sprintf( "(rc_namespace != '%s' AND rc_namespace != '%s')", $ns1, $ns2 ),
+                               "rc_type != '6'",
+                               "(rc_namespace != '$ns1' AND rc_namespace != '$ns2')",
                        ],
                        [
                                'namespace' => $ns1,
@@ -143,8 +153,8 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                $this->assertConditions(
                        [ # expected
                                'rc_bot' => 0,
-                               0 => "rc_user != '{$user->getId()}'",
-                               1 => "rc_type != '6'",
+                               "rc_user != '{$user->getId()}'",
+                               "rc_type != '6'",
                        ],
                        [
                                'hidemyself' => 1,
@@ -157,8 +167,8 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                $this->assertConditions(
                        [ # expected
                                'rc_bot' => 0,
-                               0 => "rc_user_text != '10.11.12.13'",
-                               1 => "rc_type != '6'",
+                               "rc_user_text != '10.11.12.13'",
+                               "rc_type != '6'",
                        ],
                        [
                                'hidemyself' => 1,
@@ -173,8 +183,8 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                $this->assertConditions(
                        [ # expected
                                'rc_bot' => 0,
-                               0 => "rc_user = '{$user->getId()}'",
-                               1 => "rc_type != '6'",
+                               "rc_user = '{$user->getId()}'",
+                               "rc_type != '6'",
                        ],
                        [
                                'hidebyothers' => 1,
@@ -187,8 +197,8 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                $this->assertConditions(
                        [ # expected
                                'rc_bot' => 0,
-                               0 => "rc_user_text = '10.11.12.13'",
-                               1 => "rc_type != '6'",
+                               "rc_user_text = '10.11.12.13'",
+                               "rc_type != '6'",
                        ],
                        [
                                'hidebyothers' => 1,
@@ -203,9 +213,9 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                $this->assertConditions(
                        [ # expected
                                'rc_bot' => 0,
-                               0 => "rc_user != '{$user->getId()}'",
-                               1 => "rc_user = '{$user->getId()}'",
-                               2 => "rc_type != '6'",
+                               "rc_user != '{$user->getId()}'",
+                               "rc_user = '{$user->getId()}'",
+                               "rc_type != '6'",
                        ],
                        [
                                'hidemyself' => 1,
@@ -215,4 +225,142 @@ class SpecialRecentchangesTest extends MediaWikiTestCase {
                        $user
                );
        }
+
+       public function testRcHidepageedits() {
+               $this->assertConditions(
+                       [ # expected
+                               'rc_bot' => 0,
+                               "rc_type != '6'",
+                               "rc_type != '0'",
+                       ],
+                       [
+                               'hidepageedits' => 1,
+                       ],
+                       "rc conditions: hidepageedits=1"
+               );
+       }
+
+       public function testRcHidenewpages() {
+               $this->assertConditions(
+                       [ # expected
+                               'rc_bot' => 0,
+                               "rc_type != '6'",
+                               "rc_type != '1'",
+                       ],
+                       [
+                               'hidenewpages' => 1,
+                       ],
+                       "rc conditions: hidenewpages=1"
+               );
+       }
+
+       public function testRcHidelog() {
+               $this->assertConditions(
+                       [ # expected
+                               'rc_bot' => 0,
+                               "rc_type != '6'",
+                               "rc_type != '3'",
+                       ],
+                       [
+                               'hidelog' => 1,
+                       ],
+                       "rc conditions: hidelog=1"
+               );
+       }
+
+       public function testRcHidehumans() {
+               $this->assertConditions(
+                       [ # expected
+                               'rc_bot' => 1,
+                               "rc_type != '6'",
+                       ],
+                       [
+                               'hidebots' => 0,
+                               'hidehumans' => 1,
+                       ],
+                       "rc conditions: hidebots=0 hidehumans=1"
+               );
+       }
+
+       public function testRcHidepatrolledDisabledFilter() {
+               $user = $this->getTestUser()->getUser();
+               $this->assertConditions(
+                       [ # expected
+                               'rc_bot' => 0,
+                               "rc_type != '6'",
+                       ],
+                       [
+                               'hidepatrolled' => 1,
+                       ],
+                       "rc conditions: hidepatrolled=1 (user not allowed)",
+                       $user
+               );
+       }
+
+       public function testRcHideunpatrolledDisabledFilter() {
+               $user = $this->getTestUser()->getUser();
+               $this->assertConditions(
+                       [ # expected
+                               'rc_bot' => 0,
+                               "rc_type != '6'",
+                       ],
+                       [
+                               'hideunpatrolled' => 1,
+                       ],
+                       "rc conditions: hideunpatrolled=1 (user not allowed)",
+                       $user
+               );
+       }
+       public function testRcHidepatrolledFilter() {
+               $user = $this->getTestSysop()->getUser();
+               $this->assertConditions(
+                       [ # expected
+                               'rc_bot' => 0,
+                               "rc_patrolled = 0",
+                               "rc_type != '6'",
+                       ],
+                       [
+                               'hidepatrolled' => 1,
+                       ],
+                       "rc conditions: hidepatrolled=1",
+                       $user
+               );
+       }
+
+       public function testRcHideunpatrolledFilter() {
+               $user = $this->getTestSysop()->getUser();
+               $this->assertConditions(
+                       [ # expected
+                               'rc_bot' => 0,
+                               "rc_patrolled = 1",
+                               "rc_type != '6'",
+                       ],
+                       [
+                               'hideunpatrolled' => 1,
+                       ],
+                       "rc conditions: hideunpatrolled=1",
+                       $user
+               );
+       }
+
+       // This is probably going to change when we do auto-fix of
+       // filters combinations that don't make sense but for now
+       // it's the behavior therefore it's the test.
+       public function testRcHidepatrolledHideunpatrolledFilter() {
+               $user = $this->getTestSysop()->getUser();
+               $this->assertConditions(
+                       [ # expected
+                               'rc_bot' => 0,
+                               "rc_patrolled = 0",
+                               "rc_patrolled = 1",
+                               "rc_type != '6'",
+                       ],
+                       [
+                               'hidepatrolled' => 1,
+                               'hideunpatrolled' => 1,
+                       ],
+                       "rc conditions: hidepatrolled=1 hideunpatrolled=1",
+                       $user
+               );
+       }
 }
index 6d17a68..62081aa 100644 (file)
@@ -58,7 +58,7 @@ class UploadFromUrlTest extends ApiTestCase {
                        $this->doApiRequest( [
                                'action' => 'upload',
                        ] );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                        $this->assertEquals( "The token parameter must be set", $e->getMessage() );
                }
@@ -70,7 +70,7 @@ class UploadFromUrlTest extends ApiTestCase {
                                'action' => 'upload',
                                'token' => $token,
                        ], $data );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                        $this->assertEquals( "One of the parameters sessionkey, file, url is required",
                                $e->getMessage() );
@@ -84,7 +84,7 @@ class UploadFromUrlTest extends ApiTestCase {
                                'url' => 'http://www.example.com/test.png',
                                'token' => $token,
                        ], $data );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                        $this->assertEquals( "The filename parameter must be set", $e->getMessage() );
                }
@@ -99,7 +99,7 @@ class UploadFromUrlTest extends ApiTestCase {
                                'filename' => 'UploadFromUrlTest.png',
                                'token' => $token,
                        ], $data );
-               } catch ( UsageException $e ) {
+               } catch ( ApiUsageException $e ) {
                        $exception = true;
                        $this->assertEquals( "Permission denied", $e->getMessage() );
                }
index e11fd8a..8ba2aeb 100644 (file)
@@ -25,14 +25,16 @@ use JsonSchema\Validator;
  */
 class ExtensionJsonValidationTest extends PHPUnit_Framework_TestCase {
 
+       /**
+        * @var ExtensionJsonValidator
+        */
+       protected $validator;
+
        public function setUp() {
                parent::setUp();
-               if ( !class_exists( Validator::class ) ) {
-                       $this->markTestSkipped(
-                               'The JsonSchema library cannot be found,' .
-                               ' please install it through composer to run extension.json validation tests.'
-                       );
-               }
+
+               $this->validator = new ExtensionJsonValidator( [ $this, 'markTestSkipped' ] );
+               $this->validator->checkDependencies();
 
                if ( !ExtensionRegistry::getInstance()->getAllThings() ) {
                        $this->markTestSkipped(
@@ -55,56 +57,12 @@ class ExtensionJsonValidationTest extends PHPUnit_Framework_TestCase {
         * @param string $path Path to thing's json file
         */
        public function testPassesValidation( $path ) {
-               $data = json_decode( file_get_contents( $path ) );
-               $this->assertInstanceOf( 'stdClass', $data, "$path is not valid JSON" );
-
-               $this->assertObjectHasAttribute( 'manifest_version', $data,
-                       "$path does not have manifest_version set." );
-               $version = $data->manifest_version;
-               if ( $version !== ExtensionRegistry::MANIFEST_VERSION ) {
-                       $schemaPath = __DIR__ . "/../../../docs/extension.schema.v$version.json";
-               } else {
-                       $schemaPath = __DIR__ . '/../../../docs/extension.schema.json';
-               }
-
-               // Not too old
-               $this->assertTrue(
-                       $version >= ExtensionRegistry::OLDEST_MANIFEST_VERSION,
-                       "$path is using a non-supported schema version"
-               );
-               // Not too new
-               $this->assertTrue(
-                       $version <= ExtensionRegistry::MANIFEST_VERSION,
-                       "$path is using a non-supported schema version"
-               );
-
-               $licenseError = false;
-               if ( class_exists( SpdxLicenses::class ) && isset( $data->{'license-name'} )
-                       // Check if it's a string, if not, schema validation will display an error
-                       && is_string( $data->{'license-name'} )
-               ) {
-                       $licenses = new SpdxLicenses();
-                       $valid = $licenses->validate( $data->{'license-name'} );
-                       if ( !$valid ) {
-                               $licenseError = '[license-name] Invalid SPDX license identifier, '
-                                       . 'see <https://spdx.org/licenses/>';
-                       }
-               }
-
-               $validator = new Validator;
-               $validator->check( $data, (object)[ '$ref' => 'file://' . $schemaPath ] );
-               if ( $validator->isValid() && !$licenseError ) {
-                       // All good.
+               try {
+                       $this->validator->validate( $path );
+                       // All good
                        $this->assertTrue( true );
-               } else {
-                       $out = "$path did pass validation.\n";
-                       foreach ( $validator->getErrors() as $error ) {
-                               $out .= "[{$error['property']}] {$error['message']}\n";
-                       }
-                       if ( $licenseError ) {
-                               $out .= "$licenseError\n";
-                       }
-                       $this->assertTrue( false, $out );
+               } catch ( ExtensionJsonValidationError $e ) {
+                       $this->assertEquals( false, $e->getMessage() );
                }
        }
 }