corona-warn-app / cwa-app-ios

Native iOS app using the exposure notification framework from Apple. The CWA development ends on May 31, 2023. You still can warn other users until April 30, 2023. More information:
https://coronawarn.app/en/faq/#ramp_down
Apache License 2.0
1.68k stars 285 forks source link

Date formatting issue in "Technical Expiration Date" box (English language issue) #3662

Closed Ein-Tim closed 3 years ago

Ein-Tim commented 3 years ago

Avoid duplicates

Technical details

Describe the bug

The date in the "Technical Expiration Date" box is wrongly formatted if the language of the device or the app is set to English:

image

Steps to reproduce the issue

  1. Set either your phone or the app language to English
  2. Open the Corona-Warn-App
  3. Click on certiifcates
  4. Add an EU digital COVID certificate if you haven't added one yet
  5. Click on the certificate
  6. Scroll all the way down
  7. Click on the certificate to open the certificates detail screen
  8. Scroll down
  9. See the box "Technical Expiration Date" with the false formatted date

Expected behaviour

There should not be a "." after the day, as this is only done in German, but not in English.

Possible Fix

Remove the dot.

Additional context

I was made aware of this issue from @MikeMcC399 in https://github.com/corona-warn-app/cwa-wishlist/issues/654#issuecomment-937526002.

MikeMcC399 commented 3 years ago

@Ein-Tim

For comparison, on CWA Android release/2.11.x, the technical expiration date of your vaccination certificate is shown depending on the locale of the device:

Locale Technical Expiration Date 24-hour Technical Expiration Date AM/PM
English (United States) Valid until 09/17/22, 16:01 Valid until 09/17/22, 4:01 PM
English (United Kingdom) Valid until 17/09/22, 16:01 Valid until 17/09/22, 4:01 pm
Deutsch (Deutschland) Gültig bis 17.09.22, 16:01 Uhr Gültig bis 17.09.22, 4:01 PM Uhr

The display of the time depends on whether the device is set to use 24-hour format or not. This can vary depending on the Android version, so the time display is not so consistent on Android. But this issue is about the date primarily in any case.

ndegendogo commented 3 years ago

1) Actually, all dates are formatted in the German style, not only the expiration date. 2) When the iPhone language is English, but the cwa is set to German, then the dates are correctly shown in the German formatting style. 3) The iPhone has separate settings for language and region. The region settings determine how dates are formatted. If you set this also to UK, you get UK formatted dates (without the dot).

Ein-Tim commented 3 years ago

@ndegendogo

Yes! You are absolutely right!

Everything's correct here, the format how the date is shown only changes when the "Region" of the phone is changed, as Region & Language are different independent settings.

Closing as not fixable, as this is not a bug.