Deprecate OC_L10N::get()
This commit is contained in:
parent
c3c7689b67
commit
a12d354762
|
@ -81,14 +81,11 @@ class OC_L10N implements \OCP\IL10N {
|
||||||
* get an L10N instance
|
* get an L10N instance
|
||||||
* @param string $app
|
* @param string $app
|
||||||
* @param string|null $lang
|
* @param string|null $lang
|
||||||
* @return \OC_L10N
|
* @return \OCP\IL10N
|
||||||
|
* @deprecated Use \OC::$server->getL10NFactory()->get() instead
|
||||||
*/
|
*/
|
||||||
public static function get($app, $lang=null) {
|
public static function get($app, $lang=null) {
|
||||||
if (is_null($lang)) {
|
return \OC::$server->getL10NFactory()->get($app, $lang);
|
||||||
return OC::$server->getL10N($app);
|
|
||||||
} else {
|
|
||||||
return new \OC_L10N($app, $lang);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -100,7 +100,7 @@ interface IL10N {
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The code (en, de, ...) of the language that is used for this OC_L10N object
|
* The code (en, de, ...) of the language that is used for this IL10N object
|
||||||
*
|
*
|
||||||
* @return string language
|
* @return string language
|
||||||
* @since 7.0.0
|
* @since 7.0.0
|
||||||
|
|
Loading…
Reference in New Issue