ocpsoft / prettytime

Social Style Date and Time Formatting for Java
http://ocpsoft.org/prettytime/
Apache License 2.0
1.29k stars 252 forks source link

DE locale: format(List<Duration>) produces wrong grammatical case #227

Closed obecker closed 2 years ago

obecker commented 2 years ago

When using prettyTime.format(durations) with a list of durations as parameter, it returns for the german locale an incorrect grammatical result. This worked correctly until release 4.0.6, it is broken since 5.0.0.

Example: expected "vor 5 Tagen 3 Stunden" actual "vor 5 Tage 3 Stunden" (expected "Tagen" but actual is "Tage")

Most probably this is a result of https://github.com/ocpsoft/prettytime/pull/193

The translation is correct for a single duration, but not for a list of durations.

lincolnthree commented 2 years ago

Closed via https://github.com/ocpsoft/prettytime/pull/229