MCPcopy Create free account
hub / github.com/akalin/gopar / getFilePath

Method getFilePath

par1/decoder.go:118–126  ·  view source on GitHub ↗
(entry fileEntry)

Source from the content-addressed store, hash-verified

116}
117
118func (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.
129func (d *Decoder) LoadFileData() error {

Callers 2

LoadFileDataMethod · 0.95
RepairMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected