From 62c5df36d611aa8f89d1b3599ec356fde2a26c46 Mon Sep 17 00:00:00 2001 From: Gilles De Mey Date: Thu, 23 Oct 2025 17:21:13 +0200 Subject: [PATCH] Alerting: Always initialize an empty slice of routes for the routingtree (#112880) --- .../apps/alerting/notifications/routingtree/conversions.go | 1 + 1 file changed, 1 insertion(+) diff --git a/pkg/registry/apps/alerting/notifications/routingtree/conversions.go b/pkg/registry/apps/alerting/notifications/routingtree/conversions.go index 70c6ee5ba0d..a200e82e309 100644 --- a/pkg/registry/apps/alerting/notifications/routingtree/conversions.go +++ b/pkg/registry/apps/alerting/notifications/routingtree/conversions.go @@ -28,6 +28,7 @@ func ConvertToK8sResource(orgID int64, r definitions.Route, version string, name RepeatInterval: optionalPrometheusDurationToString(r.RepeatInterval), Receiver: r.Receiver, }, + Routes: make([]model.RoutingTreeRoute, 0, len(r.Routes)), } for _, route := range r.Routes { if route == nil {