Several speed improvements (magiclink, caching, indexes)
[friendica.git/.git] / src / Module / RandomProfile.php
index 65ce565..163fec6 100644 (file)
@@ -34,10 +34,10 @@ class RandomProfile extends BaseModule
        {
                $a = DI::app();
 
-               $contactUrl = Contact::getRandomUrl();
+               $contact = Contact::getRandomContact();
 
-               if ($contactUrl) {
-                       $link = Contact::magicLink($contactUrl);
+               if (!empty($contact)) {
+                       $link = Contact::magicLinkByContact($contact);
                        $a->redirect($link);
                }