diff options
Diffstat (limited to 'cmd/serv.go')
-rw-r--r-- | cmd/serv.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cmd/serv.go b/cmd/serv.go index 1e66cb5111..a8db623e16 100644 --- a/cmd/serv.go +++ b/cmd/serv.go @@ -6,7 +6,6 @@ package cmd import ( - "encoding/json" "fmt" "net/http" "net/url" @@ -25,6 +24,7 @@ import ( "code.gitea.io/gitea/modules/setting" "github.com/dgrijalva/jwt-go" + jsoniter "github.com/json-iterator/go" "github.com/kballard/go-shellquote" "github.com/urfave/cli" ) @@ -255,6 +255,7 @@ func runServ(c *cli.Context) error { } tokenAuthentication.Header["Authorization"] = fmt.Sprintf("Bearer %s", tokenString) + json := jsoniter.ConfigCompatibleWithStandardLibrary enc := json.NewEncoder(os.Stdout) err = enc.Encode(tokenAuthentication) if err != nil { |