aboutsummaryrefslogtreecommitdiffstats
path: root/utils/fs/memory
diff options
context:
space:
mode:
authorMáximo Cuadros <mcuadros@gmail.com>2016-11-20 11:30:01 +0100
committerMáximo Cuadros <mcuadros@gmail.com>2016-11-20 11:30:01 +0100
commit2e60c554dbe56eed3e9a503d03fed01b459d029a (patch)
tree47ef669288c73147f1d0992912f8228828d3d5b4 /utils/fs/memory
parent16d86605732ba3198c0acd4317b53cf4991a7d4d (diff)
downloadgo-git-2e60c554dbe56eed3e9a503d03fed01b459d029a.tar.gz
utils: fs, memory fix ReadDir, error getting filename
Diffstat (limited to 'utils/fs/memory')
-rw-r--r--utils/fs/memory/memory.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/utils/fs/memory/memory.go b/utils/fs/memory/memory.go
index ef54c37..398ac35 100644
--- a/utils/fs/memory/memory.go
+++ b/utils/fs/memory/memory.go
@@ -91,7 +91,7 @@ func (fs *Memory) ReadDir(base string) (entries []fs.FileInfo, err error) {
parts := strings.Split(fullpath, string(separator))
if len(parts) == 1 {
- entries = append(entries, newFileInfo(fs.base, fullpath, f.content.Len()))
+ entries = append(entries, &fileInfo{name: parts[0], size: f.content.Len()})
continue
}