fix(time): Try LC_TIME before LANG
This commit is contained in:
parent
93e3b0f8f3
commit
77e6fc5908
1 changed files with 1 additions and 1 deletions
|
|
@ -114,7 +114,7 @@ impl cosmic::Application for Window {
|
||||||
_flags: Self::Flags,
|
_flags: Self::Flags,
|
||||||
) -> (Self, cosmic::iced::Command<app::Message<Self::Message>>) {
|
) -> (Self, cosmic::iced::Command<app::Message<Self::Message>>) {
|
||||||
fn get_local() -> Result<Locale, Box<dyn std::error::Error>> {
|
fn get_local() -> Result<Locale, Box<dyn std::error::Error>> {
|
||||||
let locale = std::env::var("LANG")?;
|
let locale = std::env::var("LC_TIME").or_else(|_| std::env::var("LANG"))?;
|
||||||
let locale = locale
|
let locale = locale
|
||||||
.split('.')
|
.split('.')
|
||||||
.next()
|
.next()
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue