]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - classes/Profile.php
Require Profile for Profile->getLists
[quix0rs-gnu-social.git] / classes / Profile.php
index 69b78e27d5f8827fa30e12a9b3b3486b7bb4e8e2..467a2601d9e87f703e391cf64e206e3a496296ee 100644 (file)
@@ -381,7 +381,7 @@ class Profile extends Managed_DataObject
         return false;
     }
 
-    function getLists($auth_user, $offset=0, $limit=null, $since_id=0, $max_id=0)
+    function getLists(Profile $scoped=null, $offset=0, $limit=null, $since_id=0, $max_id=0)
     {
         $ids = array();
 
@@ -421,9 +421,7 @@ class Profile extends Managed_DataObject
             self::cacheSet($keypart, implode(',', $ids));
         }
 
-        $showPrivate = (($auth_user instanceof User ||
-                            $auth_user instanceof Profile) &&
-                        $auth_user->id === $this->id);
+        $showPrivate = $this->sameAs($scoped);
 
         $lists = array();