Return group color if language has none

This commit is contained in:
Lauris BH
2020-03-21 15:37:39 +02:00
parent cfaa7a1711
commit 97a26011a9
13 changed files with 293 additions and 1 deletions

View File

@ -471,3 +471,12 @@ func GetLanguageByAlias(alias string) (lang string, ok bool) {
return
}
// GetLanguageGroup returns language group or empty string if language does not have group.
func GetLanguageGroup(language string) string {
if group, ok := data.LanguagesGroup[language]; ok {
return group
}
return ""
}