Skip to content

Commit 9ef6c69

Browse files
Send updatedAt timestamp in api response
1 parent 8f38002 commit 9ef6c69

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/Transformers/DocumentTransformer.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,10 @@ class DocumentTransformer extends TransformerAbstract
1010
public function transform(Document $document)
1111
{
1212
return [
13-
'type' => $document->type,
14-
'title' => $document->title,
15-
'body' => $document->body
13+
'type' => $document->type,
14+
'title' => $document->title,
15+
'body' => $document->body,
16+
'updatedAt' => $this->updated_at->toIso8601String()
1617
];
1718
}
1819
}

0 commit comments

Comments
 (0)