MCPcopy Index your code
hub / github.com/foxcpp/maddy / closeIfNeeded

Function closeIfNeeded

internal/cli/ctl/moduleinit.go:34–40  ·  view source on GitHub ↗
(i any)

Source from the content-addressed store, hash-verified

32)
33
34func closeIfNeeded(i any) {
35 if c, ok := i.(container.LifetimeModule); ok {
36 if err := c.Stop(); err != nil {
37 log.DefaultLogger.Error("failed to stop module", err)
38 }
39 }
40}
41
42type managedStorage struct {
43 module.ManageableStorage

Callers 3

initFunction · 0.85
initFunction · 0.85
initFunction · 0.85

Calls 2

StopMethod · 0.65
ErrorMethod · 0.45

Tested by

no test coverage detected