r106604 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r106603‎ | r106604 | r106605 >
Date:21:43, 18 December 2011
Author:jeroendedauw
Status:ok
Tags:
Comment:
compat w/ mw 1.18
Modified paths:
  • /trunk/extensions/EducationProgram/includes/EPPager.php (modified) (history)
  • /trunk/extensions/EducationProgram/specials/SpecialEPPage.php (modified) (history)

Diff [purge]

Index: trunk/extensions/EducationProgram/specials/SpecialEPPage.php
@@ -110,5 +110,16 @@
111111 );
112112 }
113113
 114+ /**
 115+ * Get the Language being used for this instance.
 116+ * getLang was deprecated in 1.19, getLanguage was introduces in the same version.
 117+ *
 118+ * @since 0.1
 119+ *
 120+ * @return Language
 121+ */
 122+ public function getLanguage() {
 123+ return method_exists( $this, 'getLanguage' ) ? $this->getLanguage() : $this->getLang();
 124+ }
114125
115126 }
Index: trunk/extensions/EducationProgram/includes/EPPager.php
@@ -83,7 +83,7 @@
8484 * @return Language
8585 */
8686 public function getLanguage() {
87 - return $this->context->getLanguage();
 87+ return method_exists( $this->context, 'getLanguage' ) ? $this->context->getLanguage() : $this->context->getLang();
8888 }
8989
9090 /**

Status & tagging log