Use UTC for published date

This commit is contained in:
bopol 2021-02-21 12:35:21 +01:00
parent cbc7603248
commit 237100da18
1 changed files with 1 additions and 1 deletions

View File

@ -517,7 +517,7 @@ struct Video
end
def published : Time
info["microformat"]?.try &.["playerMicroformatRenderer"]?.try &.["publishDate"]?.try { |t| Time.parse(t.as_s, "%Y-%m-%d", Time::Location.local) } || Time.local
info["microformat"]?.try &.["playerMicroformatRenderer"]?.try &.["publishDate"]?.try { |t| Time.parse(t.as_s, "%Y-%m-%d", Time::Location::UTC) } || Time.utc
end
def published=(other : Time)