Alerting: Fix newlines in text/plain template (#70207)

Alerting: Fix newlines in text/plain template at last
This commit is contained in:
George Robinson
2023-06-16 09:02:58 +01:00
committed by GitHub
parent 9ed09257fe
commit a773b722b1
2 changed files with 6 additions and 6 deletions

View File

@@ -7,7 +7,7 @@ You have {{ len .Alerts.Firing }} firing alert(s), and {{ len .Alerts.Resolved }
{{ template "__default_alerts_summarize" .Alerts.Firing }}
{{- end }}
{{ if .Alerts.Resolved -}}
{{- if .Alerts.Resolved }}
({{ len .Alerts.Resolved }}) RESOLVED
-------------
{{ template "__default_alerts_summarize" .Alerts.Resolved }}
@@ -51,13 +51,13 @@ Annotations: {{ template "__default_sorted_pairs" $annotations }}
{{- define "__default_sorted_pairs" -}}
{{ range .SortedPairs }}
{{ .Name }} = {{ .Value }}
- {{ .Name }} = {{ .Value }}
{{- end }}
{{- end -}}
{{- if .Message -}}
{{ .Message }}
{{ else -}}
{{- else -}}
{{ template "__default_message" . }}
{{- end }}