From 94e9e44a67ab09c2823940b82d66e524ed77ec3e Mon Sep 17 00:00:00 2001 From: oda Date: Tue, 21 Jul 2015 15:18:43 +0900 Subject: [PATCH] fix a bug that invalid convert to asset name if recursive --- convert.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/convert.go b/convert.go index 30a41a0..cf0466e 100644 --- a/convert.go +++ b/convert.go @@ -173,8 +173,9 @@ func findFiles(dir, prefix string, recursive bool, toc *[]Asset, ignore []*regex if file.IsDir() { if recursive { + recursivePath := filepath.Join(dir, file.Name()) visitedPaths[asset.Path] = true - findFiles(asset.Path, prefix, recursive, toc, ignore, knownFuncs, visitedPaths) + findFiles(recursivePath, prefix, recursive, toc, ignore, knownFuncs, visitedPaths) } continue } else if file.Mode()&os.ModeSymlink == os.ModeSymlink {