[PLUGIN][ActivityPub][Model][Note] Add name property as note title
This commit is contained in:
@@ -147,6 +147,7 @@ class Note extends Model
|
||||
'created' => new DateTime($type_note->get('published') ?? 'now'),
|
||||
'content' => $type_note->get('content') ?? null,
|
||||
'rendered' => $type_note->has('content') ? HTML::sanitize($type_note->get('content')) : null,
|
||||
'title' => $type_note->get('name') ?? null,
|
||||
'content_type' => 'text/html',
|
||||
'language_id' => $type_note->get('contentLang') ?? null,
|
||||
'url' => $type_note->get('url') ?? $type_note->get('id'),
|
||||
@@ -336,6 +337,7 @@ class Note extends Model
|
||||
'id' => $object->getUrl(),
|
||||
'published' => $object->getCreated()->format(DateTimeInterface::RFC3339),
|
||||
'attributedTo' => $object->getActor()->getUri(Router::ABSOLUTE_URL),
|
||||
'name' => $object->getTitle(),
|
||||
'content' => $object->getRendered(),
|
||||
'mediaType' => 'text/html',
|
||||
'source' => ['content' => $object->getContent(), 'mediaType' => $object->getContentType()],
|
||||
|
Reference in New Issue
Block a user