public function getContext() {
if ( $this->context === null ) {
$class = get_class( $this );
- wfDebug( __METHOD__ . " ($class): called and \$context is null. Using RequestContext::getMain() for sanity\n" );
+ wfDebug( __METHOD__ . " ($class): called and \$context is null. " .
+ "Using RequestContext::getMain() for sanity\n" );
$this->context = RequestContext::getMain();
}
+
return $this->context;
}
$this->context = $context;
}
+ /**
+ * Get the SiteConfiguration object
+ *
+ * @since 1.23
+ * @return SiteConfiguration
+ */
+ public function getConfig() {
+ return $this->getContext()->getConfig();
+ }
+
/**
* Get the WebRequest object
*
*/
public function getLang() {
wfDeprecated( __METHOD__, '1.19' );
+
return $this->getLanguage();
}
*/
public function msg( /* $args */ ) {
$args = func_get_args();
+
return call_user_func_array( array( $this->getContext(), 'msg' ), $args );
}