log errors when running a module instance

This commit is contained in:
Joel Wetzell
2025-11-23 10:29:28 -06:00
parent 5b58cca360
commit f7cdcd62cc

View File

@@ -121,7 +121,10 @@ func (r *Router) Run() {
moduleInstance.RegisterRouter(r)
r.moduleWait.Add(1)
go func() {
moduleInstance.Run()
err := moduleInstance.Run()
if err != nil {
slog.Error("error encountered running module", "id", moduleInstance.Id(), "error", err)
}
r.moduleWait.Done()
}()
}