fixing false undefined error
This commit is contained in:
parent
7cba7d1117
commit
2bf9323203
@ -20,13 +20,12 @@ package paths
|
||||
|
||||
import (
|
||||
"errors"
|
||||
`fmt`
|
||||
`io/fs`
|
||||
"fmt"
|
||||
"io/fs"
|
||||
"os"
|
||||
"os/user"
|
||||
"path/filepath"
|
||||
`strings`
|
||||
|
||||
"strings"
|
||||
// "syscall"
|
||||
)
|
||||
|
||||
@ -113,6 +112,8 @@ func MakeDirIfNotExist(path string) (err error) {
|
||||
if !stat.Mode().IsDir() {
|
||||
err = errors.New(fmt.Sprintf("path %v exists but is not a directory", locPath))
|
||||
return
|
||||
} else {
|
||||
return
|
||||
}
|
||||
|
||||
// This should probably never happen. Probably.
|
||||
|
Loading…
Reference in New Issue
Block a user