MCPcopy Index your code
hub / github.com/perkeep/perkeep / blobFromURLPath

Function blobFromURLPath

pkg/blobserver/gethandler/get.go:128–134  ·  view source on GitHub ↗
(path string)

Source from the content-addressed store, hash-verified

126var dummyModTime = time.Unix(1276213335, 0)
127
128func blobFromURLPath(path string) blob.Ref {
129 matches := getPattern.FindStringSubmatch(path)
130 if len(matches) != 3 {
131 return blob.Ref{}
132 }
133 return blob.ParseOrZero(strings.TrimPrefix(matches[0], "/camli/"))
134}

Callers 2

TestBlobFromURLPathFunction · 0.85
ServeHTTPMethod · 0.85

Calls 1

ParseOrZeroFunction · 0.92

Tested by 1

TestBlobFromURLPathFunction · 0.68