mirror of
https://github.com/miniflux/v2.git
synced 2025-06-27 16:36:00 +00:00
Update date parser to fix another time zone issue
The Washington Post has its feeds with EST, which is getting parsed by miniflux as UTC, and showing up as 8 hours off. See http://feeds.washingtonpost.com/rss/politics for an example. This fix applies a similar workaround for EST/EDT as was done for PST/PDT.
This commit is contained in:
parent
03cfbfe4ac
commit
793f475edd
2 changed files with 32 additions and 0 deletions
|
@ -340,5 +340,9 @@ func parseLocalTimeDates(layout, ds string) (t time.Time, err error) {
|
|||
loc, _ = time.LoadLocation("America/Los_Angeles")
|
||||
}
|
||||
|
||||
if strings.HasSuffix(ds, "EST") || strings.HasSuffix(ds, "EDT") {
|
||||
loc, _ = time.LoadLocation("America/New_York")
|
||||
}
|
||||
|
||||
return time.ParseInLocation(layout, ds, loc)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue