mirror of
https://github.com/iv-org/invidious.git
synced 2024-11-12 18:04:30 +01:00
Update src/invidious/jsonify/api_v1/video_json.cr
Co-authored-by: Samantaz Fox <coding@samantaz.fr>
This commit is contained in:
parent
b526f48120
commit
eed14d08a8
1 changed files with 1 additions and 1 deletions
|
@ -246,7 +246,7 @@ module Invidious::JSONify::APIv1
|
|||
json.field "viewCountText", rv["short_view_count"]?
|
||||
json.field "viewCount", rv["view_count"]?.try &.empty? ? nil : rv["view_count"].to_i64
|
||||
json.field "published", rv["published"]?
|
||||
if !rv["published"].nil?
|
||||
if !rv["published"]?.nil?
|
||||
json.field "publishedText", translate(locale, "`x` ago", recode_date(Time.parse_rfc3339(rv["published"].to_s), locale))
|
||||
else
|
||||
json.field "publishedText", ""
|
||||
|
|
Loading…
Reference in a new issue