(entry fileEntry)
| 116 | } |
| 117 | |
| 118 | func (d *Decoder) getFilePath(entry fileEntry) (string, error) { |
| 119 | filename := entry.filename |
| 120 | if filepath.Base(filename) != filename { |
| 121 | return "", errors.New("bad filename") |
| 122 | } |
| 123 | |
| 124 | basePath := filepath.Dir(d.indexFile) |
| 125 | return filepath.Join(basePath, filename), nil |
| 126 | } |
| 127 | |
| 128 | // LoadFileData loads existing file data into memory. |
| 129 | func (d *Decoder) LoadFileData() error { |
no outgoing calls
no test coverage detected