Skip to content

Locale update#935

Merged
praveek merged 13 commits intoadobe:dev-v4.0.0from
sbenedicadb:locale-update
May 30, 2023
Merged

Locale update#935
praveek merged 13 commits intoadobe:dev-v4.0.0from
sbenedicadb:locale-update

Conversation

@sbenedicadb
Copy link
Copy Markdown
Member

Description

  • use bcp47 format locales for lifecycle v2 on ios 16 or newer
  • add preferred language locale to lifecycle and lifecycle v2 metrics
  • change accept-language header and user agent locales to use preferred language

Related Issue

Motivation and Context

How Has This Been Tested?

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • I have signed the Adobe Open Source CLA.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

Copy link
Copy Markdown
Contributor

@kevinlind kevinlind left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Left one small comment to update the documentation on the LifecycleUtils formatting function.


/// Return a string for the given 'locale' identifier.
/// Returns a BCP formatted locale from the calling locale String.
/// Uses the format "`Locale.languageCode`-`Locale.regionCode`".
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you update this comment to clarify?

Uses Locale.identifier(.bcp47) for iOS 16+, otherwise uses format "Locale.languageCode-Locale.regionCode"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants