remove unused
https://github.com/go-jet/jet/pull/458#discussion_r1986128416
This commit is contained in:
parent
ec4bf00276
commit
77dc0bcb57
2 changed files with 5 additions and 25 deletions
|
|
@ -56,24 +56,3 @@ func EnsureDirPathExist(dirPath string) error {
|
|||
|
||||
return nil
|
||||
}
|
||||
|
||||
// RemoveDir deletes everything at folder dir.
|
||||
func RemoveDir(dir string) error {
|
||||
if err := os.RemoveAll(dir); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
// DirExists checks if folder at path exist.
|
||||
func DirExists(path string) (bool, error) {
|
||||
_, err := os.Stat(path)
|
||||
if err == nil {
|
||||
return true, nil
|
||||
}
|
||||
if os.IsNotExist(err) {
|
||||
return false, nil
|
||||
}
|
||||
return true, err
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue