diff options
-rw-r--r-- | cmd/rescribe/main.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd/rescribe/main.go b/cmd/rescribe/main.go index ff4d582..54338f3 100644 --- a/cmd/rescribe/main.go +++ b/cmd/rescribe/main.go @@ -214,7 +214,7 @@ These training files are included in rescribe, and are always available: // if trainingPath doesn't exist, set it to the embedded training instead _, err = os.Stat(trainingPath) - if !os.IsExist(err) { + if err != nil && !os.IsExist(err) { trainingPath = filepath.Base(trainingPath) trainingPath = filepath.Join(tessdatadir, trainingPath) } |