Fix filename.

This commit is contained in:
Nuno Cruces 2023-04-22 10:40:23 +01:00
parent 723cb6bdb6
commit ee60339b2d

View file

@ -334,6 +334,9 @@ func splitDirAndName(path string) (dir, name string, err error) {
return path, "", nil
}
dir, name = filepath.Split(path)
if dir == "" {
return "", name, nil
}
_, err = os.Stat(dir)
return dir, name, err
}