MCPcopy Create free account
hub / github.com/Unpackerr/unpackerr / getPasswordFromPath

Method getPasswordFromPath

pkg/unpackerr/handlers.go:159–169  ·  view source on GitHub ↗
(path string)

Source from the content-addressed store, hash-verified

157}
158
159func (u *Unpackerr) getPasswordFromPath(path string) string {
160 start, end := strings.Index(path, "{{"), strings.Index(path, "}}")
161
162 if start == -1 || end == -1 || start > end {
163 return ""
164 }
165
166 u.Debugf("Found password in Path: %s", path[start+2:end])
167
168 return path[start+2 : end]
169}
170
171// checkExtractDone checks if an extracted and imported item needs to be deleted.
172// Or if an extraction failed and needs to be restarted.

Callers 2

extractTrackedItemMethod · 0.95

Calls 1

DebugfMethod · 0.65

Tested by

no test coverage detected