From 434ee838ddb0b83f6119630cddeb16e17d27c053 Mon Sep 17 00:00:00 2001 From: RiceChuan Date: Thu, 12 Dec 2024 10:32:57 +0800 Subject: [PATCH] chore: use errors.New to replace fmt.Errorf with no parameters Signed-off-by: RiceChuan --- cmd/headscale/cli/mockoidc.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cmd/headscale/cli/mockoidc.go b/cmd/headscale/cli/mockoidc.go index 309ad67d..9969f7c6 100644 --- a/cmd/headscale/cli/mockoidc.go +++ b/cmd/headscale/cli/mockoidc.go @@ -2,6 +2,7 @@ package cli import ( "encoding/json" + "errors" "fmt" "net" "net/http" @@ -68,7 +69,7 @@ func mockOIDC() error { userStr := os.Getenv("MOCKOIDC_USERS") if userStr == "" { - return fmt.Errorf("MOCKOIDC_USERS not defined") + return errors.New("MOCKOIDC_USERS not defined") } var users []mockoidc.MockUser