$object->type = (empty($notice->object_type)) ? ActivityObject::NOTE : $notice->object_type;
$object->id = $notice->uri;
- $object->title = 'New ' . ActivityObject::canonicalType($notice->object_type)
- . ' by ' . $notice->getProfile()->nickname;
+ $object->title = 'New ' . ActivityObject::canonicalType($object->type) . ' by ';
+ try {
+ $object->title .= $notice->getProfile()->getAcctUri();
+ } catch (ProfileNoAcctUriException $e) {
+ $object->title .= $e->profile->nickname;
+ }
$object->content = $notice->rendered;
$object->link = $notice->bestUrl();