From: Evan Prodromou Date: Mon, 13 Sep 2010 20:23:10 +0000 (-0400) Subject: accept null constructor for ActivityContext X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=d207f19d227c675329db3f339d865c9b45219af2;p=quix0rs-gnu-social.git accept null constructor for ActivityContext --- diff --git a/lib/activitycontext.php b/lib/activitycontext.php index 09a4579249..f568c791ff 100644 --- a/lib/activitycontext.php +++ b/lib/activitycontext.php @@ -54,8 +54,12 @@ class ActivityContext const MENTIONED = 'mentioned'; const CONVERSATION = 'ostatus:conversation'; - function __construct($element) + function __construct($element = null) { + if (empty($element)) { + return; + } + $replyToEl = ActivityUtils::child($element, self::INREPLYTO, self::THR); if (!empty($replyToEl)) {