catch err

This commit is contained in:
2025-10-21 11:03:23 +02:00
parent 4ed1f26694
commit dc8b99379a

View File

@@ -46,5 +46,7 @@ func Run() {
slog.Info("start testing and serving metrics on localhost", "port", conf.Port)
slog.Info("test setup", "file", conf.File, "labels", strings.Join(conf.Label, ","))
http.ListenAndServe(fmt.Sprintf(":%d", conf.Port), nil)
if err := http.ListenAndServe(fmt.Sprintf(":%d", conf.Port), nil); err != nil {
log.Fatal(err)
}
}