Sophivorus has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/394825 )

Change subject: Respond to Reedy's code review
......................................................................

Respond to Reedy's code review

- Add README with install, config and usage instructions
- Improve parseParams method
- Clean API requests in the getExtract method
- Replace language guessing for config option set to target wiki
- Remove span crediting Wikipedia, see docs
- Remove obsolete messages

Bug: T149766
Change-Id: Ie139099bbcdca924520858d4c1dde1c87d4d217e
---
A README
M WikipediaExtracts.php
M WikipediaExtractsError.php
M extension.json
M i18n/ast.json
M i18n/be-tarask.json
M i18n/bn.json
M i18n/de.json
M i18n/en.json
M i18n/es.json
M i18n/fa.json
M i18n/fr.json
M i18n/gl.json
M i18n/it.json
M i18n/kab.json
M i18n/ko.json
M i18n/lb.json
M i18n/lt.json
M i18n/lv.json
M i18n/mk.json
M i18n/nb.json
M i18n/nl.json
M i18n/oc.json
M i18n/pl.json
M i18n/pt-br.json
M i18n/pt.json
M i18n/qqq.json
M i18n/roa-tara.json
M i18n/ru.json
M i18n/sr-ec.json
M i18n/sv.json
M i18n/uk.json
M i18n/vi.json
M i18n/zh-hans.json
34 files changed, 80 insertions(+), 162 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikipediaExtracts 
refs/changes/25/394825/1

diff --git a/README b/README
new file mode 100644
index 0000000..763fb5c
--- /dev/null
+++ b/README
@@ -0,0 +1,35 @@
+# WikipediaExtracts
+
+MediaWiki extension that enables the inserting of content extracted directly 
from Wikipedia.
+
+## Installation
+
+Simply add the following code to the bottom of your LocalSettings.php:
+
+wfLoadExtension( 'WikipediaExtracts' );
+
+## Configuration
+
+By default, WikipediaExtracts will extract content from the English Wikipedia.
+To extract content from other Wikipedias, or other MediaWiki wikis altogether,
+set $WikipediaExtractsAPI to the URL of the API of the target wiki. For 
example,
+to extract content from the Spanish Wikipedia:
+
+$wgWikipediaExtractsAPI = "https://es.wikipedia.org/w/api.php";;
+
+Warning! The target wiki has to have the Extension:TextExtracts enabled!
+All Wikimedia Foundation wikis have it enabled by default, but other wikis may 
not.
+
+## Usage
+
+Basic usage to extract a full article:
+
+{{#WikipediaExtract:Title of the article}}
+
+To extract just the introduction of the article:
+
+{{#WikipediaExtract:Title of the article
+|intro = true
+}}
+
+See more options at https://www.mediawiki.org/wiki/Extension:WikipediaExtracts
\ No newline at end of file
diff --git a/WikipediaExtracts.php b/WikipediaExtracts.php
index 682dc76..2427873 100644
--- a/WikipediaExtracts.php
+++ b/WikipediaExtracts.php
@@ -6,17 +6,12 @@
         * @var string $userAgent User agent for querying the API
         */
        private static $userAgent =
-               'Extension:WikipediaExtracts/2.1 
(https://www.mediawiki.org/wiki/Extension:WikipediaExtracts)';
+               'Extension:WikipediaExtracts/3.0 
(https://www.mediawiki.org/wiki/Extension:WikipediaExtracts)';
 
        /**
         * @var Parser $parser Parser object
         */
        private static $parser;
-
-       /**
-        * @var Language $contentLanguage Language object of the content 
language of the local wiki
-        */
-       public static $contentLanguage;
 
        /**
         * @var array $params Associative array of the parameters passed to the 
parser function
@@ -27,11 +22,6 @@
         * @var string $wikipediaTitle Title of the Wikipedia article to extract
         */
        private static $wikipediaTitle;
-
-       /**
-        * @var string $wikipediaLanguage Language code of the Wikipedia to 
query
-        */
-       private static $wikipediaLanguage;
 
        /**
         * Main hook
@@ -53,17 +43,10 @@
        public static function onFunctionHook( Parser $parser, $input = null ) {
                try {
                        self::$parser = $parser;
-                       self::$contentLanguage = $parser->getTargetLanguage();
                        self::$params = self::parseParams( array_slice( 
func_get_args(), 2 ) );
                        self::$wikipediaTitle = self::getWikipediaTitle( $input 
);
-                       self::$wikipediaLanguage = self::getWikipediaLanguage( 
$input );
 
                        $html = self::getExtract();
-
-                       global $wgWikipediaExtractsAddCredits;
-                       if ( $wgWikipediaExtractsAddCredits ) {
-                               $html .= self::getCredits();
-                       }
                } catch ( WikipediaExtractsError $error ) {
                        $html = $error->getHtmlMessage();
                }
@@ -94,29 +77,6 @@
        }
 
        /**
-        * Get the language code of the Wikipedia to query
-        *
-        * @param string $input A language code or a URL from which to extract 
the language code
-        * @return string $wikipediaLanguage The language code of the Wikipedia 
to query
-        * @throws WikipediaExtractsError
-        */
-       private static function getWikipediaLanguage( $input ) {
-               if ( $input && filter_var( $input, FILTER_VALIDATE_URL ) ) {
-                       MediaWiki\suppressWarnings();
-                       // Example host "en.wikipedia.org"
-                       $host = explode( '.', parse_url( $input, PHP_URL_HOST ) 
);
-                       MediaWiki\restoreWarnings();
-                       $wikipediaLanguage = $host[0];
-               } else {
-                       $wikipediaLanguage = self::getParam( 'language', 
self::$contentLanguage->getCode() );
-               }
-               if ( !Language::isValidCode( $wikipediaLanguage ) ) {
-                       throw new WikipediaExtractsError( 'invalid-language', 
$wikipediaLanguage );
-               }
-               return $wikipediaLanguage;
-       }
-
-       /**
         * Get a param value out of the $params array
         *
         * @param string $key of the param
@@ -141,14 +101,11 @@
        private static function parseParams( array $params ) {
                $array = [];
                foreach ( $params as $param ) {
-                       $pair = explode( '=', $param, 2 );
+                       $pair = array_map( 'trim', explode( '=', $param, 2 ) );
                        if ( count( $pair ) === 2 ) {
-                               $name = trim( $pair[0] );
-                               $value = trim( $pair[1] );
-                               $array[ $name ] = $value;
+                               $array[ $pair[0] ] = $pair[1];
                        } elseif ( count( $pair ) === 1 ) {
-                               $name = trim( $pair[0] );
-                               $array[ $name ] = true;
+                               $array[ $pair[0] ] = true;
                        }
                }
                return $array;
@@ -177,23 +134,21 @@
                        'format' => 'json',
                        'formatversion' => 2
                ];
-               $query = 'https://' . self::$wikipediaLanguage
-                       . '.wikipedia.org/w/api.php?' . http_build_query( $data 
);
+               $data = array_filter( $data );
+               global $wgWikipediaExtractsAPI;
+               $query = $wgWikipediaExtractsAPI . '?' . http_build_query( 
$data );
                $request = MWHttpRequest::factory( $query );
                $request->setUserAgent( self::$userAgent );
                $status = $request->execute();
                if ( !$status->isOK() ) {
-                       if ( $status->getValue() === 100 ) {
-                               throw new WikipediaExtractsError( 
'invalid-language', self::$wikipediaLanguage );
-                       }
-                       throw new WikipediaExtractsError( 'error' );
+                       throw new WikipediaExtractsError;
                }
                $content = FormatJson::decode( $request->getContent() );
                if ( !$content ) {
-                       throw new WikipediaExtractsError( 'error' );
+                       throw new WikipediaExtractsError;
                }
                if ( array_key_exists( 'error-codes', $content ) ) {
-                       throw new WikipediaExtractsError( 'error' );
+                       throw new WikipediaExtractsError;
                }
                foreach ( $content->query->pages as $page ) {
                        if ( property_exists( $page, 'missing' ) ) {
@@ -201,22 +156,5 @@
                        }
                        return $page->extract;
                }
-       }
-
-       /**
-        * Get a span with a link to Wikipedia
-        *
-        * @return string
-        */
-       private static function getCredits() {
-               $title = Title::newFromText( self::$wikipediaTitle );
-               $url = 'https://' . self::$wikipediaLanguage . 
'.wikipedia.org/wiki/' . $title->getPartialURL();
-               return Html::rawElement(
-                       'small', [
-                               'lang' => self::$contentLanguage->getHtmlCode(),
-                               'dir' => self::$contentLanguage->getDir()
-                       ],
-                       wfMessage( 'wikipediaextracts-credits', $url 
)->inContentLanguage()->plain()
-               );
        }
 }
diff --git a/WikipediaExtractsError.php b/WikipediaExtractsError.php
index 83a3c6c..e321346 100644
--- a/WikipediaExtractsError.php
+++ b/WikipediaExtractsError.php
@@ -21,7 +21,7 @@
         * @param string $messageKey Key identifying the type of error
         * @param string $messageParam Extra data about the error
         */
-       public function __construct( $messageKey, $messageParam = null ) {
+       public function __construct( $messageKey = 'error', $messageParam = 
null ) {
                $this->messageKey = $messageKey;
                $this->messageParam = $messageParam;
        }
diff --git a/extension.json b/extension.json
index 353df3e..a0cd60c 100644
--- a/extension.json
+++ b/extension.json
@@ -1,6 +1,6 @@
 {
        "name": "WikipediaExtracts",
-       "version": "2.1",
+       "version": "3.0",
        "author": "[http://mediawiki.org/wiki/User:Sophivorus Felipe Schenone]",
        "url": "https://www.mediawiki.org/wiki/Extension:WikipediaExtracts";,
        "descriptionmsg": "wikipediaextracts-desc",
@@ -21,7 +21,7 @@
                "ParserFirstCallInit": 
"WikipediaExtracts::onParserFirstCallInit"
        },
        "config": {
-               "WikipediaExtractsAddCredits": true
+               "WikipediaExtractsAPI": "https://en.wikipedia.org/w/api.php";
        },
        "manifest_version": 1
 }
diff --git a/i18n/ast.json b/i18n/ast.json
index 7db6be6..7ed3ac8 100644
--- a/i18n/ast.json
+++ b/i18n/ast.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Permite insertar conteníu estrayíu 
direutamente de Wikipedia.",
-       "wikipediaextracts-404": "Nun s'atopó la páxina «$1» en Wikipedia",
-       "wikipediaextracts-invalid-language": "El códigu d'idioma «$1» nun ye 
válidu",
-       "wikipediaextracts-credits": "Estrayíu de [$1 Wikipedia]"
+       "wikipediaextracts-404": "Nun s'atopó la páxina «$1» en Wikipedia"
 }
diff --git a/i18n/be-tarask.json b/i18n/be-tarask.json
index 89bb628..48d2030 100644
--- a/i18n/be-tarask.json
+++ b/i18n/be-tarask.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Дазваляе ўлучаць зьмест, атрыманы непасрэдна 
зь Вікіпэдыі.",
-       "wikipediaextracts-404": "Старонка «$1» ня знойдзеная ў Вікіпэдыі",
-       "wikipediaextracts-invalid-language": "Код мовы «$1» няслушны",
-       "wikipediaextracts-credits": "Атрыманае зь [$1 Вікіпэдыі]"
+       "wikipediaextracts-404": "Старонка «$1» ня знойдзеная ў Вікіпэдыі"
 }
diff --git a/i18n/bn.json b/i18n/bn.json
index f529067..99f4df0 100644
--- a/i18n/bn.json
+++ b/i18n/bn.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "উইকিপিডিয়া থেকে সরাসরি নিষ্কাশিত বিষয়বস্তু 
সন্নিবেশ করা সক্ষম করে।",
-       "wikipediaextracts-404": "'$1' পাতাটি উইকিপিডিয়ায় পাওয়া যায়নি",
-       "wikipediaextracts-invalid-language": "ভাষা কোড '$1' অবৈধ",
-       "wikipediaextracts-credits": "[$1 উইকিপিডিয়া] থেকে নিষ্কাশিত"
+       "wikipediaextracts-404": "'$1' পাতাটি উইকিপিডিয়ায় পাওয়া যায়নি"
 }
diff --git a/i18n/de.json b/i18n/de.json
index b6eaaaa..f082a4f 100644
--- a/i18n/de.json
+++ b/i18n/de.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Ermöglicht das Einfügen von Inhaltsauszügen 
direkt aus der Wikipedia",
-       "wikipediaextracts-404": "Die Seite „$1“ wurde in der Wikipedia nicht 
gefunden",
-       "wikipediaextracts-invalid-language": "Der Sprachcode „$1“ ist 
ungültig",
-       "wikipediaextracts-credits": "Auszug aus [$1 Wikipedia]"
+       "wikipediaextracts-404": "Die Seite „$1“ wurde in der Wikipedia nicht 
gefunden"
 }
diff --git a/i18n/en.json b/i18n/en.json
index dbd6a39..301d97a 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -5,7 +5,6 @@
                ]
        },
        "wikipediaextracts-desc": "Enables the inserting of content extracted 
directly from Wikipedia",
-       "wikipediaextracts-404": "Page '$1' was not found in Wikipedia",
-       "wikipediaextracts-invalid-language": "Language code '$1' is invalid",
-       "wikipediaextracts-credits": "Extracted from [$1 Wikipedia]"
+       "wikipediaextracts-404": "Page '$1' was not found",
+       "wikipediaextracts-error": "There was an error while extracting content"
 }
diff --git a/i18n/es.json b/i18n/es.json
index c2023d7..2bdea14 100644
--- a/i18n/es.json
+++ b/i18n/es.json
@@ -6,7 +6,6 @@
                ]
        },
        "wikipediaextracts-desc": "Permite insertar contenido extraído 
directamente de Wikipedia.",
-       "wikipediaextracts-404": "No se encontró la página «$1» en Wikipedia",
-       "wikipediaextracts-invalid-language": "El código de idioma «$1» no es 
válido",
-       "wikipediaextracts-credits": "Extraído de [$1 Wikipedia]"
+       "wikipediaextracts-404": "No se encontró la página «$1»",
+       "wikipediaextracts-error": "Hubo un error al extraer contenido"
 }
diff --git a/i18n/fa.json b/i18n/fa.json
index 7baab1c..4ed7cb6 100644
--- a/i18n/fa.json
+++ b/i18n/fa.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "قراردادن محتوای مستقیماً استخراج‌شده از 
ویکی‌پدیا را ممکن می‌کند.",
-       "wikipediaextracts-404": "صفحهٔ «$1» در ویکی‌پدیا یافت نشد",
-       "wikipediaextracts-invalid-language": "کد زبان «$1» نامعتبر است",
-       "wikipediaextracts-credits": "استخراج‌شده از [$1 ویکی‌پدیا]"
+       "wikipediaextracts-404": "صفحهٔ «$1» در ویکی‌پدیا یافت نشد"
 }
diff --git a/i18n/fr.json b/i18n/fr.json
index 10c3f0b..518da7c 100644
--- a/i18n/fr.json
+++ b/i18n/fr.json
@@ -8,7 +8,5 @@
                ]
        },
        "wikipediaextracts-desc": "Permet d’insérer du contenu extrait 
directement de Wikipédia",
-       "wikipediaextracts-404": "La page '$1' n'a pas été trouvée sur 
Wikipédia",
-       "wikipediaextracts-invalid-language": "The language code '$1' is 
invalid",
-       "wikipediaextracts-credits": "Extrait de [$1 Wikipédia]"
+       "wikipediaextracts-404": "La page '$1' n'a pas été trouvée sur 
Wikipédia"
 }
diff --git a/i18n/gl.json b/i18n/gl.json
index ca98890..3d0331a 100644
--- a/i18n/gl.json
+++ b/i18n/gl.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Permite inserir contido extraído 
directamente de Wikipedia.",
-       "wikipediaextracts-404": "A páxina '$1' non foi atopada na Wikipedia",
-       "wikipediaextracts-invalid-language": "O código de lingua '$1' non é 
válido",
-       "wikipediaextracts-credits": "Extraído de [$1 Wikipedia]"
+       "wikipediaextracts-404": "A páxina '$1' non foi atopada na Wikipedia"
 }
diff --git a/i18n/it.json b/i18n/it.json
index 842db3d..063021c 100644
--- a/i18n/it.json
+++ b/i18n/it.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Consente di inserire contenuti estratti 
direttamente da Wikipedia.",
-       "wikipediaextracts-404": "La pagina '$1' non è stata trovata in 
Wikipedia",
-       "wikipediaextracts-invalid-language": "Il codice di lingua '$1' non è 
valido",
-       "wikipediaextracts-credits": "Estratto da [$1 Wikipedia]"
+       "wikipediaextracts-404": "La pagina '$1' non è stata trovata in 
Wikipedia"
 }
diff --git a/i18n/kab.json b/i18n/kab.json
index 71f1a98..68a04e3 100644
--- a/i18n/kab.json
+++ b/i18n/kab.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Ad isireg taguri n ugbur i d-yettwakksen 
srid si wikipedia",
-       "wikipediaextracts-404": "Asebter '$1' ulac-it di Wikipedia",
-       "wikipediaextracts-invalid-language": "Tangalt n tutlayt '$1' mačči d 
tameɣtut",
-       "wikipediaextracts-credits": "Tukkist n [$1 Wikipedia]"
+       "wikipediaextracts-404": "Asebter '$1' ulac-it di Wikipedia"
 }
diff --git a/i18n/ko.json b/i18n/ko.json
index 29a215f..2abdb2a 100644
--- a/i18n/ko.json
+++ b/i18n/ko.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "위키백과로부터 직접 가져온 내용을 추가할 수 있게 합니다",
-       "wikipediaextracts-404": "'$1' 페이지는 위키백과에서 찾을 수 없습니다",
-       "wikipediaextracts-invalid-language": "'$1' 언어 코드는 올바르지 않습니다",
-       "wikipediaextracts-credits": "[$1 위키백과]에서 발췌"
+       "wikipediaextracts-404": "'$1' 페이지는 위키백과에서 찾을 수 없습니다"
 }
diff --git a/i18n/lb.json b/i18n/lb.json
index e0d173b..f43c6cb 100644
--- a/i18n/lb.json
+++ b/i18n/lb.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Erméiglecht et fir Inhalt, deen direkt aus 
der Wikipedia erausgeholl gouf, dranzesetzen.",
-       "wikipediaextracts-404": "D'Säit '$1' gouf op Wikipedia net fonnt",
-       "wikipediaextracts-invalid-language": "De Sproochecode '$1' ass net 
valabel.",
-       "wikipediaextracts-credits": "Extrait aus der [$1 Wikipedia]"
+       "wikipediaextracts-404": "D'Säit '$1' gouf op Wikipedia net fonnt"
 }
diff --git a/i18n/lt.json b/i18n/lt.json
index 6fe72e6..2a57ccb 100644
--- a/i18n/lt.json
+++ b/i18n/lt.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Leidžia įterpti turinį, gauta tiesiai iš 
Vikipedijos.",
-       "wikipediaextracts-404": "Puslapis '$1' nebuvo rastas Vikipedijoje",
-       "wikipediaextracts-invalid-language": "Kalbos kodas '$1' negalimas",
-       "wikipediaextracts-credits": "Gauta iš [$1 Vikipedijos]"
+       "wikipediaextracts-404": "Puslapis '$1' nebuvo rastas Vikipedijoje"
 }
diff --git a/i18n/lv.json b/i18n/lv.json
index ba6e4ab..c3e0ef8 100644
--- a/i18n/lv.json
+++ b/i18n/lv.json
@@ -3,6 +3,5 @@
                "authors": [
                        "Papuass"
                ]
-       },
-       "wikipediaextracts-invalid-language": "Valodas kods '$1' nav derīgs"
+       }
 }
diff --git a/i18n/mk.json b/i18n/mk.json
index 26529dd..a3fdd5a 100644
--- a/i18n/mk.json
+++ b/i18n/mk.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Овозможува вметнување на содржини извлечени 
право од Википедија.",
-       "wikipediaextracts-404": "Не ја најдов страницата „$1“ на Википедија на 
англиски",
-       "wikipediaextracts-invalid-language": "Јазичниот код „$13 е неважечки",
-       "wikipediaextracts-credits": "Извлечено од [$1 Википедија]"
+       "wikipediaextracts-404": "Не ја најдов страницата „$1“ на Википедија на 
англиски"
 }
diff --git a/i18n/nb.json b/i18n/nb.json
index 2d0da1d..9014d60 100644
--- a/i18n/nb.json
+++ b/i18n/nb.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Gjør det mulig å sette inn innhold hentet 
direkte fra Wikipedia.",
-       "wikipediaextracts-404": "Siden «$1» ble ikke funnet på Wikipedia",
-       "wikipediaextracts-invalid-language": "Språkkoden «$1» er ugyldig",
-       "wikipediaextracts-credits": "Hentet fra [$1 Wikipedia]"
+       "wikipediaextracts-404": "Siden «$1» ble ikke funnet på Wikipedia"
 }
diff --git a/i18n/nl.json b/i18n/nl.json
index 0c3934a..83dcc00 100644
--- a/i18n/nl.json
+++ b/i18n/nl.json
@@ -6,6 +6,5 @@
                ]
        },
        "wikipediaextracts-desc": "Maakt direct invoegen van inhoud uit 
Wikipedia mogelijk",
-       "wikipediaextracts-404": "De pagina '$1' is niet gevonden op Wikipedia",
-       "wikipediaextracts-invalid-language": "De taalcode '$1' is ongeldig"
+       "wikipediaextracts-404": "De pagina '$1' is niet gevonden op Wikipedia"
 }
diff --git a/i18n/oc.json b/i18n/oc.json
index cb8c54c..846376b 100644
--- a/i18n/oc.json
+++ b/i18n/oc.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Permet d'inserir de contengut extrait 
dirèctament de Wikipèdia.",
-       "wikipediaextracts-404": "La pagina '$1' es pas estada trobada sus 
Wikipèdia",
-       "wikipediaextracts-invalid-language": "Lo còdi de lenga «$1» es 
invalid",
-       "wikipediaextracts-credits": "Extrait de [$1 Wikipèdia]"
+       "wikipediaextracts-404": "La pagina '$1' es pas estada trobada sus 
Wikipèdia"
 }
diff --git a/i18n/pl.json b/i18n/pl.json
index 1b78832..e42f9dd 100644
--- a/i18n/pl.json
+++ b/i18n/pl.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Pozwala wstawiać fragmenty treści 
bezpośrednio z Wikipedii.",
-       "wikipediaextracts-404": "Strona '$1' nie została znaleziona w 
Wikipedii",
-       "wikipediaextracts-invalid-language": "Kod języka '$1' jest 
nieprawidłowy",
-       "wikipediaextracts-credits": "Fragment z [$1 Wikipedii]"
+       "wikipediaextracts-404": "Strona '$1' nie została znaleziona w 
Wikipedii"
 }
diff --git a/i18n/pt-br.json b/i18n/pt-br.json
index 5428b6e..2b6964a 100644
--- a/i18n/pt-br.json
+++ b/i18n/pt-br.json
@@ -6,7 +6,5 @@
                ]
        },
        "wikipediaextracts-desc": "Permite inserir conteúdo extraído 
diretamente da Wikipédia.",
-       "wikipediaextracts-404": "A página '$1' não foi encontrada na 
Wikipédia",
-       "wikipediaextracts-invalid-language": "O código de língua '$1' é 
inválido",
-       "wikipediaextracts-credits": "Extraído da [$1 Wikipédia]"
+       "wikipediaextracts-404": "A página '$1' não foi encontrada na Wikipédia"
 }
diff --git a/i18n/pt.json b/i18n/pt.json
index 0126b31..4c929e2 100644
--- a/i18n/pt.json
+++ b/i18n/pt.json
@@ -6,7 +6,5 @@
                ]
        },
        "wikipediaextracts-desc": "Permite inserir conteúdo extraído 
diretamente da Wikipédia.",
-       "wikipediaextracts-404": "A página '$1' não foi encontrada na 
Wikipédia",
-       "wikipediaextracts-invalid-language": "O código de língua '$1' é 
inválido",
-       "wikipediaextracts-credits": "Extraído da [$1 Wikipédia]"
+       "wikipediaextracts-404": "A página '$1' não foi encontrada na Wikipédia"
 }
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 4d5ca5a..f8da6c3 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": 
"{{desc|name=WikipediaExtracts|url=https://www.mediawiki.org/wiki/Extension:WikipediaExtracts}}";,
-       "wikipediaextracts-404": "Error message when an extract is requested of 
a Wikipedia page that doesn't exist",
-       "wikipediaextracts-invalid-language": "Error message when given an 
invalid language code",
-       "wikipediaextracts-credits": "Text after the extract, crediting 
Wikipedia"
+       "wikipediaextracts-404": "Error message when an extract is requested of 
a Wikipedia page that doesn't exist"
 }
diff --git a/i18n/roa-tara.json b/i18n/roa-tara.json
index 997b757..4c7fd14 100644
--- a/i18n/roa-tara.json
+++ b/i18n/roa-tara.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Abbilite 'u 'nzerimende d'u condenute 
estratte direttamende da Uicchipèdie.",
-       "wikipediaextracts-404": "'A pàgenà '$1' non g'ha state acchiate jndr'à 
Uicchipèdie",
-       "wikipediaextracts-invalid-language": "'U codece d'a lènghe '$1' non 
g'è valide",
-       "wikipediaextracts-credits": "Estratte da [$1 Uicchipèdie]"
+       "wikipediaextracts-404": "'A pàgenà '$1' non g'ha state acchiate jndr'à 
Uicchipèdie"
 }
diff --git a/i18n/ru.json b/i18n/ru.json
index af6885b..c00439a 100644
--- a/i18n/ru.json
+++ b/i18n/ru.json
@@ -7,7 +7,5 @@
                ]
        },
        "wikipediaextracts-desc": "Позволяет вставить содержимое, извлечённое 
непосредственно из Википедии.",
-       "wikipediaextracts-404": "Страница '$1' не найдена в Википедии",
-       "wikipediaextracts-invalid-language": "Код языка «$1» не является 
допустимым",
-       "wikipediaextracts-credits": "Извлеченно из [$1 Википедии]"
+       "wikipediaextracts-404": "Страница '$1' не найдена в Википедии"
 }
diff --git a/i18n/sr-ec.json b/i18n/sr-ec.json
index e6820be..75248b4 100644
--- a/i18n/sr-ec.json
+++ b/i18n/sr-ec.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Омогућавање убацивања садржаја извученог 
директно са Википедије",
-       "wikipediaextracts-404": "Страница '$1' није пронађена на Википедији",
-       "wikipediaextracts-invalid-language": "Језички код '$1' је невалидан",
-       "wikipediaextracts-credits": "Извучено са [$1 Википедије]"
+       "wikipediaextracts-404": "Страница '$1' није пронађена на Википедији"
 }
diff --git a/i18n/sv.json b/i18n/sv.json
index 2e70aa2..e4b97d8 100644
--- a/i18n/sv.json
+++ b/i18n/sv.json
@@ -4,6 +4,5 @@
                        "WikiPhoenix"
                ]
        },
-       "wikipediaextracts-404": "Sidan \"$1\" hittades inte på Wikipedia",
-       "wikipediaextracts-credits": "Extraherad från [$1 Wikipedia]"
+       "wikipediaextracts-404": "Sidan \"$1\" hittades inte på Wikipedia"
 }
diff --git a/i18n/uk.json b/i18n/uk.json
index 8af2d5b..3fe8392 100644
--- a/i18n/uk.json
+++ b/i18n/uk.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Дає можливість вставляти контент, видобутий 
безпосередньо з Вікіпедії.",
-       "wikipediaextracts-404": "Сторінку «$1» не знайдено у Вікіпедії",
-       "wikipediaextracts-invalid-language": "Код мови «$1» недійсний",
-       "wikipediaextracts-credits": "Витяг із [$1 Вікіпедії]"
+       "wikipediaextracts-404": "Сторінку «$1» не знайдено у Вікіпедії"
 }
diff --git a/i18n/vi.json b/i18n/vi.json
index 29788a6..99fe1d7 100644
--- a/i18n/vi.json
+++ b/i18n/vi.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "Chèn nội dung trích dẫn trực tiếp từ 
Wikipedia.",
-       "wikipediaextracts-404": "Không tìm thấy trang “$1” trong Wikipedia",
-       "wikipediaextracts-invalid-language": "Mã ngôn ngữ “$1” không hợp lệ",
-       "wikipediaextracts-credits": "Trích dẫn từ [$1 Wikipedia]"
+       "wikipediaextracts-404": "Không tìm thấy trang “$1” trong Wikipedia"
 }
diff --git a/i18n/zh-hans.json b/i18n/zh-hans.json
index 577322a..0bb870f 100644
--- a/i18n/zh-hans.json
+++ b/i18n/zh-hans.json
@@ -5,7 +5,5 @@
                ]
        },
        "wikipediaextracts-desc": "允许插入直接提取自维基百科的内容。",
-       "wikipediaextracts-404": "在维基百科找不到页面“$1”",
-       "wikipediaextracts-invalid-language": "语言代码“$1”无效",
-       "wikipediaextracts-credits": "提取自[$1 维基百科]"
+       "wikipediaextracts-404": "在维基百科找不到页面“$1”"
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/394825
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie139099bbcdca924520858d4c1dde1c87d4d217e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikipediaExtracts
Gerrit-Branch: master
Gerrit-Owner: Sophivorus <scheno...@gmail.com>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to