MCPcopy
hub / github.com/slimtoolkit/slim / doCleanup

Method doCleanup

pkg/app/execontext.go:39–51  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

37}
38
39func (ref *ExecutionContext) doCleanup() {
40 if len(ref.cleanupHandlers) == 0 {
41 return
42 }
43
44 //call cleanup handlers in reverse order
45 for i := len(ref.cleanupHandlers) - 1; i >= 0; i-- {
46 cleanup := ref.cleanupHandlers[i]
47 if cleanup != nil {
48 cleanup()
49 }
50 }
51}
52
53func (ref *ExecutionContext) FailOn(err error) {
54 if err != nil {

Callers 3

ExitMethod · 0.95
FailOnMethod · 0.95
FailMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected