File tree 1 file changed +2
-2
lines changed 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -115,7 +115,7 @@ func NegotiateIncludingOpenMetrics(h http.Header) Format {
115
115
// for FmtOpenMetrics, but a future (breaking) release will add the Close method
116
116
// to the Encoder interface directly. The current version of the Encoder
117
117
// interface is kept for backwards compatibility.
118
- func NewEncoder (w io.Writer , format Format ) Encoder {
118
+ func NewEncoder (w io.Writer , format Format , options ... ToOpenMetricsOption ) Encoder {
119
119
switch format {
120
120
case FmtProtoDelim :
121
121
return encoderCloser {
@@ -152,7 +152,7 @@ func NewEncoder(w io.Writer, format Format) Encoder {
152
152
case FmtOpenMetrics_0_0_1 , FmtOpenMetrics_1_0_0 :
153
153
return encoderCloser {
154
154
encode : func (v * dto.MetricFamily ) error {
155
- _ , err := MetricFamilyToOpenMetrics (w , v )
155
+ _ , err := MetricFamilyToOpenMetrics (w , v , options ... )
156
156
return err
157
157
},
158
158
close : func () error {
You can’t perform that action at this time.
0 commit comments