MCPcopy Index your code
hub / github.com/dgraph-io/dgraph / pathExist

Function pathExist

worker/backup_handler.go:210–216  ·  view source on GitHub ↗

pathExist checks if a path (file or dir) is found at target. Returns true if found, false otherwise.

(path string)

Source from the content-addressed store, hash-verified

208// pathExist checks if a path (file or dir) is found at target.
209// Returns true if found, false otherwise.
210func pathExist(path string) bool {
211 _, err := os.Stat(path)
212 if err == nil {
213 return true
214 }
215 return !os.IsNotExist(err) && !os.IsPermission(err)
216}
217
218// S3 Handler.
219

Callers 2

DirExistsMethod · 0.85
FileExistsMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected