mirror of
https://github.com/miniflux/v2.git
synced 2025-07-22 17:18:37 +00:00
Add workaround to handle some invalid dates
This commit is contained in:
parent
5877048749
commit
e60e0ba3c4
3 changed files with 12 additions and 8 deletions
|
@ -293,6 +293,8 @@ var invalidLocalizedDateReplacer = strings.NewReplacer(
|
|||
"mai ", "May ",
|
||||
"jui ", "Jun ",
|
||||
"juin ", "June ",
|
||||
"Thurs,", "Thu,",
|
||||
"Thur,", "Thu,",
|
||||
)
|
||||
|
||||
// Parse parses a given date string using a large
|
||||
|
|
|
@ -178,6 +178,8 @@ func TestParseWeirdDateFormat(t *testing.T) {
|
|||
"2018-10-23 04:07:42 +00:00",
|
||||
"5 August, 2019",
|
||||
"mar., 01 déc. 2020 16:11:02 +0000",
|
||||
"Thurs, 15 Oct 2020 00:00:39 +0000",
|
||||
"Thur, 19 Nov 2020 00:00:39 +0000",
|
||||
}
|
||||
|
||||
for _, date := range dates {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue