]> git.mxchange.org Git - friendica.git/blobdiff - mod/wall_attach.php
Expose IHTTPClient::request()
[friendica.git] / mod / wall_attach.php
index 8cb19ab1a09e4953e1a2653c667553358260fb23..9d5641874ba68453b2834e6a386093da795de89f 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
  *
@@ -31,8 +31,8 @@ function wall_attach_post(App $a) {
 
        $r_json = (!empty($_GET['response']) && $_GET['response']=='json');
 
-       if ($a->argc > 1) {
-               $nick = $a->argv[1];
+       if (DI::args()->getArgc() > 1) {
+               $nick = DI::args()->getArgv()[1];
                $r = q("SELECT `user`.*, `contact`.`id` FROM `user` LEFT JOIN `contact` on `user`.`uid` = `contact`.`uid`  WHERE `user`.`nickname` = '%s' AND `user`.`blocked` = 0 and `contact`.`self` = 1 LIMIT 1",
                        DBA::escape($nick)
                );