MCPcopy
hub / github.com/tailscale/golink / deleteLinkStats

Function deleteLinkStats

golink.go:374–381  ·  view source on GitHub ↗

deleteLinkStats removes the link stats from memory.

(link *Link)

Source from the content-addressed store, hash-verified

372
373// deleteLinkStats removes the link stats from memory.
374func deleteLinkStats(link *Link) {
375 stats.mu.Lock()
376 delete(stats.clicks, link.Short)
377 delete(stats.dirty, link.Short)
378 stats.mu.Unlock()
379
380 db.DeleteStats(link.Short)
381}
382
383// redirectHandler returns the http.Handler for serving all plaintext HTTP
384// requests. It redirects all requests to the HTTPs version of the same URL.

Callers 1

serveDeleteFunction · 0.85

Calls 1

DeleteStatsMethod · 0.80

Tested by

no test coverage detected