Skip to content

Commit

Permalink
fix(search): no exception for notExist
Browse files Browse the repository at this point in the history
  • Loading branch information
Gusted committed Aug 6, 2021
1 parent cb63f56 commit 860f8fd
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions search/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@ const indexFile = "data/styles.bleve"

func openBleveIndexFile(path string) (bleve.Index, error) {
_, err := os.Stat(path)
if err != nil && os.IsNotExist(err) {
return nil, nil
} else if err != nil {
if err != nil {
return nil, err
}

Expand Down

0 comments on commit 860f8fd

Please sign in to comment.