mirror of
https://github.com/actions-runner-controller/actions-runner-controller.git
synced 2026-10-17 23:30:43 +02:00
Read the e2e Go version from go.mod and apply the safe go fix modernizers (#4677)
This commit is contained in:
+2
-6
@@ -4,6 +4,7 @@ import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"os"
|
||||
"slices"
|
||||
"strconv"
|
||||
"time"
|
||||
|
||||
@@ -78,10 +79,5 @@ func NewLogger(logLevel string, logFormat string) (logr.Logger, error) {
|
||||
|
||||
func validLogFormat(logFormat string) bool {
|
||||
validFormat := []string{"text", "json"}
|
||||
for _, v := range validFormat {
|
||||
if v == logFormat {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return false
|
||||
return slices.Contains(validFormat, logFormat)
|
||||
}
|
||||
|
||||
@@ -35,7 +35,7 @@ func (t Transport) log(req *http.Request, resp *http.Response) {
|
||||
return
|
||||
}
|
||||
|
||||
var args []interface{}
|
||||
var args []any
|
||||
|
||||
marked := resp.Header.Get(httpcache.XFromCache) == "1"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user