MCPcopy
hub / github.com/ossf/scorecard / Init

Method Init

internal/gitfile/gitfile.go:49–56  ·  view source on GitHub ↗
(ctx context.Context, cloneURL, commitSHA string)

Source from the content-addressed store, hash-verified

47}
48
49func (h *Handler) Init(ctx context.Context, cloneURL, commitSHA string) {
50 h.errSetup = nil
51 h.once = new(sync.Once)
52 h.ctx = ctx
53 h.cloneURL = cloneURL
54 h.commitSHA = commitSHA
55 h.files = nil
56}
57
58func (h *Handler) setup() error {
59 h.once.Do(func() {

Callers 5

TestHandlerFunction · 0.95
TestHandlerPathTraversalFunction · 0.95
newInMemoryRepoFunction · 0.80
InitRepoMethod · 0.80

Calls

no outgoing calls

Tested by 2

TestHandlerFunction · 0.76
TestHandlerPathTraversalFunction · 0.76