Fix database presence check
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
parent
3e0c110893
commit
e772ecf2ab
@ -71,6 +71,6 @@ func init() {
|
|||||||
|
|
||||||
DBPath = filepath.Join(CacheDir, "db")
|
DBPath = filepath.Join(CacheDir, "db")
|
||||||
|
|
||||||
_, err = os.ReadDir(DBPath)
|
fi, err := os.Stat(DBPath)
|
||||||
DBPresent = err == nil
|
DBPresent = err == nil && !fi.IsDir()
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user