Merge pull request #1797 from B0pol/published_utc

Use UTC for published date
このコミットが含まれているのは:
TheFrenchGhosty 2021-02-25 17:57:02 +01:00 committed by GitHub
コミット 705e4fca06
この署名に対応する既知のキーがデータベースに存在しません
GPGキーID: 4AEE18F83AFDEB23
1個のファイルの変更1行の追加1行の削除

ファイルの表示

@ -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)