From 0737ea6b04dbc0204a9f5d227e70cb09c31596cb Mon Sep 17 00:00:00 2001 From: cwkuo Date: Fri, 29 Jul 2016 22:40:47 +0800 Subject: [PATCH] Fix os.IsExist() condition in filelist.Contains() --- filelist.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/filelist.go b/filelist.go index 114fce6..88ec7d9 100644 --- a/filelist.go +++ b/filelist.go @@ -59,7 +59,7 @@ func (f *filelist) Contains(pathname string) bool { // Finally try absolute path st, e := os.Stat(rel) - if !os.IsNotExist(e) && st.IsDir() && strings.HasPrefix(abs, rel) { + if os.IsExist(e) && st.IsDir() && strings.HasPrefix(abs, rel) { return true }