]> git.mxchange.org Git - friendica.git/blobdiff - mod/videos.php
Merge pull request #10479 from MrPetovan/task/9378-merge-share-template
[friendica.git] / mod / videos.php
index a3344a8b4300d2c04550489c35f07a286bb55a7c..89097f5cde3f4a4cb6e5792b8a5bb3d1b9f2e546 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /**
- * @copyright Copyright (C) 2020, Friendica
+ * @copyright Copyright (C) 2010-2021, the Friendica project
  *
  * @license GNU AGPL version 3 or any later version
  *
@@ -30,10 +30,9 @@ use Friendica\DI;
 use Friendica\Model\Attach;
 use Friendica\Model\Contact;
 use Friendica\Model\Item;
-use Friendica\Model\Profile;
 use Friendica\Model\User;
 use Friendica\Module\BaseProfile;
-use Friendica\Util\Security;
+use Friendica\Security\Security;
 
 function videos_init(App $a)
 {
@@ -56,7 +55,7 @@ function videos_init(App $a)
                $a->data['user'] = $user[0];
                $a->profile_uid = $user[0]['uid'];
 
-               $profile = Profile::getByNickname($nick, $a->profile_uid);
+               $profile = User::getOwnerDataByNick($nick);
 
                $account_type = Contact::getAccountType($profile);
 
@@ -126,7 +125,7 @@ function videos_content(App $a)
 
 
        if (DI::config()->get('system', 'block_public') && !Session::isAuthenticated()) {
-               notice(DI::l10n()->t('Public access denied.') . EOL);
+               notice(DI::l10n()->t('Public access denied.'));
                return;
        }
 
@@ -179,7 +178,7 @@ function videos_content(App $a)
        }
 
        if ($a->data['user']['hidewall'] && (local_user() != $owner_uid) && !$remote_contact) {
-               notice(DI::l10n()->t('Access to this item is restricted.') . EOL);
+               notice(DI::l10n()->t('Access to this item is restricted.'));
                return;
        }