Add "updated" field to item export

This commit is contained in:
Peter Stuifzand 2018-04-07 01:58:03 +02:00
parent e4540ab2b3
commit cbd6e7dd84
2 changed files with 5 additions and 0 deletions

View File

@ -181,6 +181,10 @@ func mapToItem(result map[string]interface{}) microsub.Item {
item.Published = published.(string)
}
if updated, e := result["updated"]; e {
item.Updated = updated.(string)
}
return item
}

View File

@ -54,6 +54,7 @@ type Item struct {
Type string `json:"type"`
Name string `json:"name,omitempty"`
Published string `json:"published"`
Updated string `json:"updated"`
URL string `json:"url"`
UID string `json:"uid"`
Author Author `json:"author"`