forked from Plemya-x/ALR
chore: fix formatting
This commit is contained in:
@ -42,18 +42,19 @@ var (
|
||||
// Subsequent calls will just return the same value.
|
||||
func Language(ctx context.Context) language.Tag {
|
||||
langMtx.Lock()
|
||||
defer langMtx.Unlock()
|
||||
if !langSet {
|
||||
syslang := SystemLang()
|
||||
tag, err := language.Parse(syslang)
|
||||
if err != nil {
|
||||
slog.Error(gotext.Get("Error parsing system language"), "err", err)
|
||||
langMtx.Unlock()
|
||||
os.Exit(1)
|
||||
}
|
||||
base, _ := tag.Base()
|
||||
lang = language.Make(base.String())
|
||||
langSet = true
|
||||
}
|
||||
langMtx.Unlock()
|
||||
return lang
|
||||
}
|
||||
|
||||
|
@ -38,7 +38,7 @@ type Paths struct {
|
||||
// using information from the system.
|
||||
// Subsequent calls will return the same value.
|
||||
//
|
||||
// Depreacted: use struct API
|
||||
// Deprecated: use struct API
|
||||
func GetPaths(ctx context.Context) *Paths {
|
||||
alrConfig := GetInstance(ctx)
|
||||
return alrConfig.GetPaths(ctx)
|
||||
|
Reference in New Issue
Block a user