...SplitN, not SplitAfterN

This commit is contained in:
2021-12-18 04:46:43 -05:00
parent cf67bec392
commit 008ed531a2
2 changed files with 3 additions and 3 deletions

View File

@@ -62,7 +62,7 @@ func ExpandHome(path *string) (err error) {
}
*/
// K but do it smarter.
unameSplit = strings.SplitAfterN(*path, string(os.PathSeparator), 2)
unameSplit = strings.SplitN(*path, string(os.PathSeparator), 2)
if len(unameSplit) != 2 {
unameSplit = append(unameSplit, "")
}