MCPcopy Create free account
hub / github.com/cloudfoundry/cli / determineLocale

Function determineLocale

util/ui/i18n.go:86–93  ·  view source on GitHub ↗
(reader LocaleReader)

Source from the content-addressed store, hash-verified

84}
85
86func determineLocale(reader LocaleReader) (string, error) {
87 locale := reader.Locale()
88 if locale == "" {
89 return defaultLocale, nil
90 }
91
92 return ParseLocale(locale)
93}
94
95func generateTranslationFunc(rawTranslation []byte) (TranslateFunc, error) {
96 var entries []TranslationEntry

Callers 1

GetTranslationFuncFunction · 0.85

Calls 2

ParseLocaleFunction · 0.85
LocaleMethod · 0.65

Tested by

no test coverage detected