Merge "content: Use Language::factory( 'en' ) instead of wfGetLangObj( 'en' )"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Fri, 18 Nov 2016 22:53:48 +0000 (22:53 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Fri, 18 Nov 2016 22:53:48 +0000 (22:53 +0000)
includes/content/CodeContentHandler.php

index 20893bb..dfd46c8 100644 (file)
 abstract class CodeContentHandler extends TextContentHandler {
 
        /**
-        * Returns the english language, because code is english, and should be handled as such.
+        * Returns the English language, because code is English, and should be handled as such.
         *
         * @param Title $title
         * @param Content $content
         *
-        * @return Language Return of wfGetLangObj( 'en' )
+        * @return Language
         *
         * @see ContentHandler::getPageLanguage()
         */
        public function getPageLanguage( Title $title, Content $content = null ) {
-               return wfGetLangObj( 'en' );
+               return Language::factory( 'en' );
        }
 
        /**
-        * Returns the english language, because code is english, and should be handled as such.
+        * Returns the English language, because code is English, and should be handled as such.
         *
         * @param Title $title
         * @param Content $content
         *
-        * @return Language Return of wfGetLangObj( 'en' )
+        * @return Language
         *
         * @see ContentHandler::getPageViewLanguage()
         */
        public function getPageViewLanguage( Title $title, Content $content = null ) {
-               return wfGetLangObj( 'en' );
+               return Language::factory( 'en' );
        }
 
        /**