优化代码

This commit is contained in:
刘祥超
2022-09-23 11:09:21 +08:00
parent 6d66d93180
commit ef6dc82f88
18 changed files with 30 additions and 23 deletions

View File

@@ -26,7 +26,7 @@ func (this *CountryOptionsAction) RunPost(params struct{}) {
}
var letter = ""
if len(country.Pinyin) > 0 && len(country.Pinyin) > 0 && len(country.Pinyin[0]) > 0 {
if len(country.Pinyin) > 0 && len(country.Pinyin[0]) > 0 {
letter = strings.ToUpper(country.Pinyin[0][:1])
}