Add 'since' to '/api/v1/auth/notifications'

This commit is contained in:
Omar Roth
2019-04-28 18:14:16 -05:00
parent ef309bd8d0
commit 54d250bde4
3 changed files with 69 additions and 25 deletions

View File

@@ -262,8 +262,10 @@ struct Video
generate_storyboards(json, self.storyboards, config, kemal_config)
end
json.field "description", html_to_content(self.description).last
json.field "descriptionHtml", html_to_content(self.description).first
description_html, description = html_to_content(self.description)
json.field "description", description
json.field "descriptionHtml", description_html
json.field "published", self.published.to_unix
json.field "publishedText", translate(locale, "`x` ago", recode_date(self.published, locale))
json.field "keywords", self.keywords