Skip to content

Commit

Permalink
fix config处理、支持冒号分隔的字典文件 2022-07-02 23:05:1656774351
Browse files Browse the repository at this point in the history
  • Loading branch information
x51pwn committed Jul 2, 2022
1 parent 2f85ca6 commit 8be59a9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -113,9 +113,9 @@ func GetVal4File(key, szDefault string) string {

// 读区配置中的字典文件
func GetVal4Filedefault(key, szDefault string) string {
s := GetVal4File(key,szDefault)
if 2 == len(strings.Split(strings.Split(s,"\n")[0],":"){
s = strings.ReplaceAll(s,":","\t")
s := GetVal4File(key, szDefault)
if 2 == len(strings.Split(strings.Split(s, "\n")[0], ":")) {
s = strings.ReplaceAll(s, ":", "\t")
}
return s
}
Expand Down

0 comments on commit 8be59a9

Please sign in to comment.