~sircmpwn/chartsrv-devel

This thread contains a patchset. You're looking at the original emails, but you may wish to use the patch review UI. Review patch

[PATCH] Remove undocumented legend option

Details
Message ID
<20201021233839.17943-1-noam@pixelhero.dev>
DKIM signature
fail
Download raw message
Patch: +0 -8 DKIM signature: fail
---
 main.go | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/main.go b/main.go
index 69fcca1..eb1b083 100644
--- a/main.go
+++ b/main.go
@@ -162,12 +162,6 @@ func registerExtension(router chi.Router, extension string, mime string) {
			height = vg.Length(h) * vg.Inch
		}

		// Undocumented option
		var legend string
		if l, ok := args["legend"]; ok {
			legend = l[0]
		}

		// Label template
		var label string
		if l, ok := args["label"]; ok {
@@ -270,8 +264,6 @@ func registerExtension(router chi.Router, extension string, mime string) {
					tmpl.Execute(&label_out, tags)
					p.Legend.Add(label_out.String(), l)
				}
			} else if legend != "" {
				p.Legend.Add(legend, l)
			} else {
				p.Legend.Add(res.Metric, l)
			}
-- 
2.28.0
Reply to thread Export thread (mbox)