'url' => $object->link,
'is_local' => Notice::REMOTE_OMB,
'source' => 'ostatus');
-
- $this->saveNoticeFromActivity($activity, $actor);
+
+ // $actor is an ostatus_profile
+ $this->saveNoticeFromActivity($activity, $actor->localProfile());
return false;
}
'is_local' => Notice::REMOTE_OMB,
'source' => 'ostatus');
- $this->saveNoticeFromActivity($activity, $actor, $options);
+ // $actor is an ostatus_profile
+ $this->saveNoticeFromActivity($activity, $actor->localProfile(), $options);
return false;
}
$options = array('source' => 'atompub');
+ // $user->getProfile() is a Profile
$this->saveNoticeFromActivity($activity,
$user->getProfile(),
$options);
'url' => $object->link,
'source' => 'restore');
+ // $user->getProfile() is a Profile
$saved = $this->saveNoticeFromActivity($activity,
$user->getProfile(),
$options);
{
// @fixme
common_log(LOG_DEBUG, "XXX activity: " . var_export($activity, true));
+ common_log(LOG_DEBUG, "XXX profile: " . var_export($profile, true));
common_log(LOG_DEBUG, "XXX options: " . var_export($options, true));
// Ok for now, we can grab stuff from the XML entry directly.
}
common_log(LOG_DEBUG, "YYY question: $question");
common_log(LOG_DEBUG, "YYY opts: " . var_export($opts, true));
+ try {
+ $notice = Poll::saveNew($profile, $question, $opts, $options);
+ common_log(LOG_DEBUG, "YYY ok: " . $notice->id);
+ return $notice;
+ } catch (Exception $e) {
+ common_log(LOG_DEBUG, "YYY fail: " . $e->getMessage());
+ }
} else {
common_log(LOG_DEBUG, "YYY no poll data");
}