fehlerbehebung

This commit is contained in:
xoy 2023-01-29 16:16:07 +01:00
parent 024214120f
commit 63212b9e89
1 changed files with 0 additions and 21 deletions

21
file.go
View File

@ -40,24 +40,3 @@ func fileCreate(filepath string) {
logger("fileCreate : unknown -> " + filepath) logger("fileCreate : unknown -> " + filepath)
} }
} }
func fileCreateDir(dirpath string) {
if _, err := os.Stat(dirpath); err == nil {
err := os.Mkdir(dirpath, 0755)
errorPanic(err)
logger("fileCreateDir : folder created -> " + dirpath)
} else if errors.Is(err, os.ErrNotExist) {
logger("fileCreateDir : folder not created -> " + dirpath)
} else {
logger("fileCreateDir : unknown -> " + dirpath)
}
}
func fileExist(filepath string) bool {
if _, err := os.Stat(filepath); err == nil {
return true
} else if errors.Is(err, os.ErrNotExist) {
return false
}
return false
}