diff options
author | Robin Appelman <icewind@owncloud.com> | 2014-08-31 10:05:59 +0200 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2014-08-31 10:08:22 +0200 |
commit | d0266c0bf85e431a3b1b39cbfaced4e8df52a264 (patch) | |
tree | dfea49fa907a3b7543f8849077d75cfc29a54279 /lib/private/share | |
parent | 23137f4798cb89b188329050a85f2f3a706947c5 (diff) | |
download | nextcloud-server-d0266c0bf85e431a3b1b39cbfaced4e8df52a264.tar.gz nextcloud-server-d0266c0bf85e431a3b1b39cbfaced4e8df52a264.zip |
Use public api for getting l10n
Diffstat (limited to 'lib/private/share')
-rw-r--r-- | lib/private/share/mailnotifications.php | 2 | ||||
-rw-r--r-- | lib/private/share/share.php | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/lib/private/share/mailnotifications.php b/lib/private/share/mailnotifications.php index 1f4645eed9f..4a92503bdd3 100644 --- a/lib/private/share/mailnotifications.php +++ b/lib/private/share/mailnotifications.php @@ -52,7 +52,7 @@ class MailNotifications { * @param string $sender user id (if nothing is set we use the currently logged-in user) */ public function __construct($sender = null) { - $this->l = \OC_L10N::get('core'); + $this->l = \OC::$server->getL10N('core'); $this->senderId = $sender; diff --git a/lib/private/share/share.php b/lib/private/share/share.php index c3593beac45..e2e9b94125e 100644 --- a/lib/private/share/share.php +++ b/lib/private/share/share.php @@ -479,7 +479,7 @@ class Share extends \OC\Share\Constants { public static function shareItem($itemType, $itemSource, $shareType, $shareWith, $permissions, $itemSourceName = null, \DateTime $expirationDate = null) { $uidOwner = \OC_User::getUser(); $shareWithinGroupOnly = self::shareWithGroupMembersOnly(); - $l = \OC_L10N::get('lib'); + $l = \OC::$server->getL10N('lib'); if (is_null($itemSourceName)) { $itemSourceName = $itemSource; @@ -849,7 +849,7 @@ class Share extends \OC\Share\Constants { * @return boolean true on success or false on failure */ public static function setPermissions($itemType, $itemSource, $shareType, $shareWith, $permissions) { - $l = \OC_L10N::get('lib'); + $l = \OC::$server->getL10N('lib'); if ($item = self::getItems($itemType, $itemSource, $shareType, $shareWith, \OC_User::getUser(), self::FORMAT_NONE, null, 1, false)) { // Check if this item is a reshare and verify that the permissions @@ -938,7 +938,7 @@ class Share extends \OC\Share\Constants { * @throws \Exception */ private static function validateExpireDate($expireDate, $shareTime, $itemType, $itemSource) { - $l = \OC_L10N::get('lib'); + $l = \OC::$server->getL10N('lib'); $date = new \DateTime($expireDate); $today = new \DateTime('now'); @@ -1083,7 +1083,7 @@ class Share extends \OC\Share\Constants { * @return \OCP\Share_Backend */ public static function getBackend($itemType) { - $l = \OC_L10N::get('lib'); + $l = \OC::$server->getL10N('lib'); if (isset(self::$backends[$itemType])) { return self::$backends[$itemType]; } else if (isset(self::$backendTypes[$itemType]['class'])) { @@ -1516,7 +1516,7 @@ class Share extends \OC\Share\Constants { private static function put($itemType, $itemSource, $shareType, $shareWith, $uidOwner, $permissions, $parentFolder = null, $token = null, $itemSourceName = null, \DateTime $expirationDate = null) { $backend = self::getBackend($itemType); - $l = \OC_L10N::get('lib'); + $l = \OC::$server->getL10N('lib'); // Check if this is a reshare if ($checkReshare = self::getItemSharedWithBySource($itemType, $itemSource, self::FORMAT_NONE, null, true)) { |