add / show comments working
This commit is contained in:
parent
a9992b0ff5
commit
6bffbc1707
10 changed files with 163 additions and 40 deletions
|
|
@ -5,7 +5,7 @@ function getFileData($file) {
|
|||
'url' => $file->url(),
|
||||
'uuid' => (string) $file->uuid(),
|
||||
'name' => $file->filename(),
|
||||
'type' => (string) $file->type()
|
||||
'type' => (string) $file->type(),
|
||||
];
|
||||
|
||||
if ($file->description()->exists()) {
|
||||
|
|
@ -13,5 +13,9 @@ function getFileData($file) {
|
|||
$data['tags'] = $file->tags()->split();
|
||||
};
|
||||
|
||||
if($file->comments()->exists()) {
|
||||
$data['comments'] = Data::decode($file->comments()->value(), 'yaml');
|
||||
}
|
||||
|
||||
return $data;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue