]> git.mxchange.org Git - friendica.git/blobdiff - src/Module/Acctlink.php
Further unused tables to be dropped
[friendica.git] / src / Module / Acctlink.php
index bcd5e19f84bfcf56642b70acdc1d8219a8759cd3..898386f3fd6f9a0b92fe86bf19873ff426410581 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
  *
@@ -22,8 +22,8 @@
 namespace Friendica\Module;
 
 use Friendica\BaseModule;
-use Friendica\Network\Probe;
 use Friendica\Core\System;
+use Friendica\Model\Contact;
 
 /**
  * Redirects to another URL based on the parameter 'addr'
@@ -35,10 +35,9 @@ class Acctlink extends BaseModule
                $addr = trim($_GET['addr'] ?? '');
 
                if ($addr) {
-                       $url = Probe::uri($addr)['url'] ?? '';
-
+                       $url = Contact::getByURL($addr)['url'] ?? '';
                        if ($url) {
-                               System::externalRedirect($url);
+                               System::externalRedirect($url['url']);
                                exit();
                        }
                }