mirror of
https://github.com/prometheus/prometheus.git
synced 2025-03-05 20:59:13 -08:00
Fix linting error
Signed-off-by: Raphael Silva <rapphil@gmail.com>
This commit is contained in:
parent
2cf34e4644
commit
ee70c9d145
|
@ -16,6 +16,7 @@ package v1
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"crypto/sha1"
|
"crypto/sha1"
|
||||||
|
"encoding/hex"
|
||||||
"errors"
|
"errors"
|
||||||
"fmt"
|
"fmt"
|
||||||
"math"
|
"math"
|
||||||
|
@ -1595,7 +1596,7 @@ func parseListRulesPaginationRequest(r *http.Request) (*listRulesPaginationReque
|
||||||
func getRuleGroupNextToken(file, group string) string {
|
func getRuleGroupNextToken(file, group string) string {
|
||||||
h := sha1.New()
|
h := sha1.New()
|
||||||
h.Write([]byte(file + ";" + group))
|
h.Write([]byte(file + ";" + group))
|
||||||
return fmt.Sprintf("%x", h.Sum(nil))
|
return hex.EncodeToString(h.Sum(nil))
|
||||||
}
|
}
|
||||||
|
|
||||||
type prometheusConfig struct {
|
type prometheusConfig struct {
|
||||||
|
|
Loading…
Reference in a new issue