Replace typehint App with AppHelper in mod folder

pull/14542/head
Art4 2024-11-10 23:37:46 +00:00
rodzic 14ec1950b9
commit 2a132718d0
4 zmienionych plików z 10 dodań i 11 usunięć

Wyświetl plik

@ -16,7 +16,7 @@
* information. * information.
*/ */
use Friendica\App; use Friendica\AppHelper;
use Friendica\Content\Conversation; use Friendica\Content\Conversation;
use Friendica\Content\Text\BBCode; use Friendica\Content\Text\BBCode;
use Friendica\Core\Hook; use Friendica\Core\Hook;
@ -330,7 +330,7 @@ function item_post_return($baseurl, $return_path)
System::jsonExit($json); System::jsonExit($json);
} }
function item_content(App $a) function item_content(AppHelper $appHelper)
{ {
if (!DI::userSession()->isAuthenticated()) { if (!DI::userSession()->isAuthenticated()) {
throw new HTTPException\UnauthorizedException(); throw new HTTPException\UnauthorizedException();

Wyświetl plik

@ -7,7 +7,7 @@
* *
*/ */
use Friendica\App; use Friendica\AppHelper;
use Friendica\Core\Renderer; use Friendica\Core\Renderer;
use Friendica\Database\DBA; use Friendica\Database\DBA;
use Friendica\DI; use Friendica\DI;
@ -15,7 +15,7 @@ use Friendica\Model\User;
use Friendica\Util\DateTimeFormat; use Friendica\Util\DateTimeFormat;
use Friendica\Util\Strings; use Friendica\Util\Strings;
function lostpass_post(App $a) function lostpass_post(AppHelper $a)
{ {
$loginame = trim($_POST['login-name']); $loginame = trim($_POST['login-name']);
if (!$loginame) { if (!$loginame) {
@ -78,7 +78,7 @@ function lostpass_post(App $a)
DI::baseUrl()->redirect(); DI::baseUrl()->redirect();
} }
function lostpass_content(App $a) function lostpass_content(AppHelper $appHelper)
{ {
if (DI::args()->getArgc() > 1) { if (DI::args()->getArgc() > 1) {
$pwdreset_token = DI::args()->getArgv()[1]; $pwdreset_token = DI::args()->getArgv()[1];

Wyświetl plik

@ -9,14 +9,14 @@
* *
*/ */
use Friendica\App; use Friendica\AppHelper;
use Friendica\Core\System; use Friendica\Core\System;
use Friendica\Database\DBA; use Friendica\Database\DBA;
use Friendica\DI; use Friendica\DI;
use Friendica\Model\Post; use Friendica\Model\Post;
use Friendica\Model\Contact; use Friendica\Model\Contact;
function update_contact_content(App $a) function update_contact_content(AppHelper $appHelper)
{ {
if (!empty(DI::args()->get(1)) && !empty($_GET['force'])) { if (!empty(DI::args()->get(1)) && !empty($_GET['force'])) {
$contact = DBA::selectFirst('account-user-view', ['pid', 'deleted'], ['id' => DI::args()->get(1)]); $contact = DBA::selectFirst('account-user-view', ['pid', 'deleted'], ['id' => DI::args()->get(1)]);

Wyświetl plik

@ -8,13 +8,12 @@
* AJAX synchronisation of notes page * AJAX synchronisation of notes page
*/ */
use Friendica\App; use Friendica\AppHelper;
use Friendica\Core\System; use Friendica\Core\System;
use Friendica\DI;
require_once 'mod/notes.php'; require_once 'mod/notes.php';
function update_notes_content(App $a) function update_notes_content(AppHelper $appHelper)
{ {
$profile_uid = intval($_GET['p']); $profile_uid = intval($_GET['p']);
@ -28,7 +27,7 @@ function update_notes_content(App $a)
* *
*/ */
$text = notes_content($a, $profile_uid); $text = notes_content($appHelper, $profile_uid);
System::htmlUpdateExit($text); System::htmlUpdateExit($text);
} }