From c86f0ffa2f7059089910b38aadd2fc018ce6d718 Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Tue, 19 Jul 2011 16:18:29 -0400 Subject: [PATCH] Avoid slurping objects recursively in activity parsing --- lib/activity.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/activity.php b/lib/activity.php index f5590047d4..12ea53a9fe 100644 --- a/lib/activity.php +++ b/lib/activity.php @@ -176,6 +176,10 @@ class Activity if ($objectEls->length > 0) { for ($i = 0; $i < $objectEls->length; $i++) { $objectEl = $objectEls->item($i); + // Only immediate children (don't slurp embedded activities' objects!) + if ($objectEl->parentNode != $entry) { + continue; + } // Special case for embedded activities $objectType = ActivityUtils::childContent($objectEl, self::OBJECTTYPE, self::SPEC); if (!empty($objectType) && $objectType == ActivityObject::ACTIVITY) { -- 2.39.5