]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
correct creation of avatar links for RSS and Posterous elements
authorEvan Prodromou <evan@status.net>
Sat, 20 Mar 2010 22:18:24 +0000 (17:18 -0500)
committerEvan Prodromou <evan@status.net>
Sat, 20 Mar 2010 22:18:24 +0000 (17:18 -0500)
lib/activityobject.php

index 18e3e21ddb2bcd9749e276b23cf706fe45c76d8d..e5cea727b77b343bcaf394e304f91d66a90a9da3 100644 (file)
@@ -297,7 +297,10 @@ class ActivityObject
         $imageEl = ActivityUtils::child($el, Activity::IMAGE, Activity::RSS);
 
         if (!empty($imageEl)) {
-            $obj->avatarLinks[] = ActivityUtils::childContent($imageEl, Activity::URL, Activity::RSS);
+            $url = ActivityUtils::childContent($imageEl, Activity::URL, Activity::RSS);
+            $al = new AvatarLink();
+            $al->url = $url;
+            $obj->avatarLinks[] = $al;
         }
 
         return $obj;
@@ -312,7 +315,9 @@ class ActivityObject
         $userImage = ActivityUtils::childContent($el, self::USERIMAGE, self::POSTEROUS);
 
         if (!empty($userImage)) {
-            $obj->avatarLinks[] = $userImage;
+            $al = new AvatarLink();
+            $al->url = $userImage;
+            $obj->avatarLinks[] = $al;
         }
 
         $obj->link = ActivityUtils::childContent($el, self::PROFILEURL, self::POSTEROUS);