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
|
||||
* @param string $app
|
||||
* @param string|null $lang
|
||||
* @return \OC_L10N
|
||||
* @return \OCP\IL10N
|
||||
* @deprecated Use \OC::$server->getL10NFactory()->get() instead
|
||||
*/
|
||||
public static function get($app, $lang=null) {
|
||||
if (is_null($lang)) {
|
||||
return OC::$server->getL10N($app);
|
||||
} else {
|
||||
return new \OC_L10N($app, $lang);
|
||||
}
|
||||
return \OC::$server->getL10NFactory()->get($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
|
||||
* @since 7.0.0
|
||||
|
|
Loading…
Reference in New Issue