diff --git a/nav.go b/nav.go index 03cfc42..a42c1dc 100644 --- a/nav.go +++ b/nav.go @@ -447,6 +447,8 @@ func (nav *nav) checkDir(dir *dir) { func (nav *nav) getDirs(wd string) { var dirs []*dir + wd = filepath.Clean(wd) + for curr, base := wd, ""; !isRoot(base); curr, base = filepath.Dir(curr), filepath.Base(curr) { dir := nav.loadDir(curr) dir.sel(base, nav.height)