]> git.mxchange.org Git - friendica.git/commitdiff
Remove unused calls of DI::app()
authorArt4 <art4@wlabs.de>
Thu, 21 Nov 2024 10:12:27 +0000 (10:12 +0000)
committerArt4 <art4@wlabs.de>
Thu, 21 Nov 2024 10:12:27 +0000 (10:12 +0000)
src/Module/Directory.php
src/Module/Invite.php
src/Module/NoScrape.php
src/Module/Profile/Schedule.php
src/Object/Post.php

index d173be6d967670ec6ace3cbcc8bc3a128c8de974..ad95b4952439484f919b7ee0985c7f7783e5066c 100644 (file)
@@ -27,7 +27,6 @@ class Directory extends BaseModule
 {
        protected function content(array $request = []): string
        {
-               $app = DI::app();
                $config = DI::config();
 
                if (($config->get('system', 'block_public') && !DI::userSession()->isAuthenticated()) ||
index 92b777b6418a085c90fb82ab30a764270491abfc..bb8f94c9a5a70b520754479e1ae074cb88956dd6 100644 (file)
@@ -30,7 +30,6 @@ class Invite extends BaseModule
 
                self::checkFormSecurityTokenRedirectOnError('/', 'send_invite');
 
-               $app = DI::app();
                $config = DI::config();
 
                $max_invites = intval($config->get('system', 'max_invites'));
@@ -117,7 +116,6 @@ class Invite extends BaseModule
                        throw new HTTPException\ForbiddenException(DI::l10n()->t('Permission denied.'));
                }
 
-               $app = DI::app();
                $config = DI::config();
 
                $inviteOnly = false;
@@ -142,7 +140,7 @@ class Invite extends BaseModule
                        if (Register::getPolicy() === Register::CLOSED) {
                                return DI::l10n()->t('Our apologies. This system is not currently configured to connect with other public sites or invite members.');
                        } else {
-                               $linkTxt = DI::l10n()->t('To accept this invitation, please visit and register at %s.', DI::baseUrl() . '/register' 
+                               $linkTxt = DI::l10n()->t('To accept this invitation, please visit and register at %s.', DI::baseUrl() . '/register'
                                        . "\r\n" . "\r\n" . DI::l10n()->t('Friendica sites all inter-connect to create a huge privacy-enhanced social web that is owned and controlled by its members. They can also connect with many traditional social networks.'));
                        }
                }
index 9ea239e0eaba5bc0ffbd05a2beca9d731cdf7a99..71a48e6f04e912df7dbc85d5a4b6f95cb7181557 100644 (file)
@@ -22,8 +22,6 @@ class NoScrape extends BaseModule
 {
        protected function rawContent(array $request = [])
        {
-               $a = DI::app();
-
                if (isset($this->parameters['nick'])) {
                        // Get infos about a specific nick (public)
                        $which = $this->parameters['nick'];
index ae64d695c97143184f78ed06fe67832378f71178..212c02b78adf0cc69a40c2d027a4e2fc78ca72e3 100644 (file)
@@ -42,8 +42,6 @@ class Schedule extends BaseProfile
                        throw new HTTPException\ForbiddenException(DI::l10n()->t('Permission denied.'));
                }
 
-               $a = DI::app();
-
                $o = self::getTabsHTML('schedule', true, DI::userSession()->getLocalUserNickname(), false);
 
                $schedule = [];
index 450af95c84373b8746db16551a44f2e2e4be849f..ead75ef60b9c92324aa32cefcb8c9dcbab4f5b42 100644 (file)
@@ -726,7 +726,7 @@ class Post
                                        $title = DI::l10n()->t('Commented by: %s', $actors);
                                        $icon  = ['fa' => 'fa-commenting', 'icon' => 'icon-commenting'];
                                        break;
-       
+
                                default:
                                        $title = DI::l10n()->t('Reacted with %s by: %s', $element['emoji'], $actors);
                                        $icon  = [];
@@ -1180,7 +1180,6 @@ class Post
         */
        protected function checkWallToWall()
        {
-               $a = DI::app();
                $conv = $this->getThread();
                $this->wall_to_wall = false;