Optimize code

This commit is contained in:
ehlxr 2018-01-25 09:45:24 +08:00
parent 224ecc42be
commit ca2738072a
3 changed files with 7 additions and 2 deletions

1
.gitignore vendored
View File

@ -17,3 +17,4 @@ vendor
JetBrainsLicenseServer*
utils/jbls/jbls
utils/jwt/jwt
.idea

3
utils/jwt/demo.json Normal file
View File

@ -0,0 +1,3 @@
{
"foo": "bar"
}

View File

@ -166,7 +166,8 @@ func signToken() error {
if err != nil {
return fmt.Errorf("Couldn't read token: %v", err)
} else if *flagDebug {
fmt.Fprintf(os.Stderr, "Token: %v bytes", len(tokData))
fmt.Fprintf(os.Stderr, "Token len: %v bytes\n", len(tokData))
fmt.Fprintf(os.Stderr, "Token data: %v \n", string(tokData))
}
// parse the JSON of the claims