mirror of
https://github.com/fumiama/jieba.git
synced 2026-06-11 20:50:29 +08:00
try to refactor, not finished yet
This commit is contained in:
4
dict.go
4
dict.go
@@ -18,11 +18,11 @@ func DictPath(dictFileName string) (string, error) {
|
||||
return dictFileName, nil
|
||||
}
|
||||
var dictFilePath string
|
||||
pwd, err := os.Getwd()
|
||||
cwd, err := os.Getwd()
|
||||
if err != nil {
|
||||
return dictFilePath, err
|
||||
}
|
||||
dictFilePath = filepath.Clean(filepath.Join(pwd, dictFileName))
|
||||
dictFilePath = filepath.Clean(filepath.Join(cwd, dictFileName))
|
||||
return dictFilePath, nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user