Update filesystem.go
authorwindch <windch@users.noreply.github.com>
Mon, 30 Sep 2013 01:05:19 +0000 (14:05 +1300)
committerNoah Campbell <noahcampbell@gmail.com>
Mon, 30 Sep 2013 02:43:38 +0000 (19:43 -0700)
bugfix: .Files() called twice in line 253, 256 in site.go. thus source files captured twice.

Signed-off-by: Noah Campbell <noahcampbell@gmail.com>
source/filesystem.go

index 6c9f4e7c15daca04f739d2475478b45319c27c75..d089c143e7cc1165908aa4ddae48e03a86f0ec86 100644 (file)
@@ -27,7 +27,7 @@ type Filesystem struct {
 }
 
 func (f *Filesystem) Files() []*File {
-       f.captureFiles()
+       if len(f.files)<1 {f.captureFiles()}
        return f.files
 }