use last modified timestamp data instead of removed 'updatedAt' field

Signed-off-by: Paul Tirk <paultirk@paultirk.com>
This commit is contained in:
Paul Tirk 2021-03-24 19:23:22 +01:00 committed by Sean Molenaar
parent 8b5715c627
commit 822423af38
2 changed files with 3 additions and 3 deletions

View File

@ -602,7 +602,7 @@ The attributes mean the following:
* **title**: Abitrary long text, item's title
* **author**: Abitrary long text, name of the author/authors
* **publishedAt**: String representing an ISO 8601 DateTime object, when the item was published
* **updatedAt**: String representing an ISO 8601 DateTime object, when the item was updated
* **lastModifiedAt**: String representing an ISO 8601 DateTime object, when the item was last modified
* **enclosure**: An enclosure object or null if none is present
* **mimeType**: Abitrary long text, the enclosures mime type
* **url**: Abitrary long text, location of the enclosure
@ -624,7 +624,7 @@ A full item contains the full content:
"title": "Plasma-nm after the solid sprint",
"author": "Jan Grulich (grulja)",
"publishedAt": "2005-08-15T15:52:01+0000",
"updatedAt": "2005-08-15T15:52:01+0000",
"lastModifiedAt": "2005-08-15T15:52:01+0000",
"enclosure": {
"mimeType": "video/webm",
"url": "http://video.webmfiles.org/elephants-dream.webm"

View File

@ -592,7 +592,7 @@ class Item extends Entity implements IAPI, \JsonSerializable
'title' => $this->getTitle(),
'author' => $this->getAuthor(),
'publishedAt' => date('c', $this->getPubDate()),
'updatedAt' => date('c', $this->getUpdatedDate()),
'lastModifiedAt' => date('c', $this->cropApiLastModified()),
'enclosure' => [
'mimeType' => $this->getEnclosureMime(),
'url' => $this->getEnclosureLink()