Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MOBILE-4010] Fix android locale override #29

Merged
merged 3 commits into from
Nov 28, 2023
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion AirshipFrameworkProxy.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

Pod::Spec.new do |s|
s.version = "5.0.1"
s.version = "5.0.2"
s.name = "AirshipFrameworkProxy"
s.summary = "Airship iOS mobile framework proxy"
s.documentation_url = "https://docs.airship.com/platform/mobile"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package com.urbanairship.android.framework.proxy.proxies

import com.urbanairship.locale.LocaleManager
import java.util.*
import java.util.Locale

public class LocaleProxy internal constructor(private val localeProvider: () -> LocaleManager) {

public fun setCurrentLocale(localeIdentifier: String) {
localeProvider().setLocaleOverride(Locale(localeIdentifier))
localeProvider().setLocaleOverride(Locale.forLanguageTag(localeIdentifier))
}

public fun getCurrentLocale(): String {
Expand All @@ -16,4 +16,4 @@ public class LocaleProxy internal constructor(private val localeProvider: () ->
public fun clearLocale() {
localeProvider().setLocaleOverride(null)
}
}
}
2 changes: 1 addition & 1 deletion android/gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[versions]

# Airship
airshipProxy = '5.0.1'
airshipProxy = '5.0.2'
airship = '17.5.0'

# Gradle plugins
Expand Down
Loading