MCPcopy
hub / github.com/git-lfs/git-lfs / DelContext

Function DelContext

errors/context.go:29–33  ·  view source on GitHub ↗

ErrorDelContext removes a value from the error's context. If the error has not been wrapped, it does nothing.

(err error, key string)

Source from the content-addressed store, hash-verified

27// ErrorDelContext removes a value from the error's context. If the error has
28// not been wrapped, it does nothing.
29func DelContext(err error, key string) {
30 if e, ok := err.(withContext); ok {
31 e.Del(key)
32 }
33}
34
35// ErrorContext returns the context map for an error if it is a wrappedError.
36// If it is not a wrappedError it will return an empty map.

Callers 1

Calls 1

DelMethod · 0.65

Tested by 1